:root {
    --bg: #f5f7f7;
    --surface: #ffffff;
    --line: #e2e8e8;
    --text: #1d2939;
    --muted: #5f6b7a;
    --accent: #123b3b;
    --accent-soft: #e5efee;
    --up: #12805c;
    --partial: #b54708;
    --down: #c4320a;
    color-scheme: light;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0f1716;
        --surface: #172221;
        --line: #26332f;
        --text: #e6ecea;
        --muted: #9aa8a5;
        --accent: #7cc4b8;
        --accent-soft: #1d2d2b;
        --up: #3ccf91;
        --partial: #f5a524;
        --down: #f97066;
        color-scheme: dark;
    }
}

* { box-sizing: border-box; }

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

a { color: var(--accent); }

.top, main, footer { width: min(880px, 100%); margin: 0 auto; padding-left: 16px; padding-right: 16px; }

.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 20px; padding-bottom: 20px; }

.mark {
    display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px;
    background: var(--accent); color: var(--surface); font-weight: 700; text-decoration: none;
}

nav { display: flex; flex-wrap: wrap; gap: 18px; }
nav a { color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 600; }
nav a:hover { color: var(--text); }

.status_link { display: inline-flex; align-items: center; gap: 7px; }

.dot { display: inline-block; flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.dot.up { background: var(--up); }
.dot.partial { background: var(--partial); }
.dot.down { background: var(--down); }

.hero { padding: 64px 0 40px; }
.hero.small { padding: 40px 0 16px; }
.eyebrow { margin: 0; color: var(--muted); font-weight: 600; }
h1 { margin: 4px 0 10px; font-size: clamp(32px, 6vw, 52px); line-height: 1.1; letter-spacing: -0.01em; }
.lead { margin: 0; max-width: 34em; color: var(--muted); font-size: 18px; }

section { padding: 24px 0; }
h2 { margin: 0 0 14px; font-size: 22px; }
.sub { margin: 0 0 16px; color: var(--muted); font-size: 14px; }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }

.card {
    display: block; padding: 20px; border: 1px solid var(--line); border-radius: 12px;
    background: var(--surface); color: var(--text);
}
.card h3 { margin: 0 0 6px; font-size: 17px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

.link_card { text-decoration: none; transition: border-color 0.15s ease, transform 0.15s ease; }
.link_card:hover { border-color: var(--accent); transform: translateY(-1px); }
.go { display: inline-block; margin-top: 12px; color: var(--accent); font-weight: 600; font-size: 14px; }

.tag {
    margin-left: 6px; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft);
    color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 0.04em; vertical-align: 2px;
}

.status_list { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; margin-bottom: 12px; }
.status_row { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 16px; padding: 16px 20px; border-top: 1px solid var(--line); }
.status_row:first-child { border-top: 0; }
.status_name { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.status_where { color: var(--muted); font-size: 13px; text-decoration: none; }
.status_state { font-size: 14px; font-weight: 600; }
.status_state.up { color: var(--up); }
.status_state.down { color: var(--down); }

@media (max-width: 600px) {
    .status_row { grid-template-columns: 1fr auto; }
    .status_where { grid-column: 1 / -1; grid-row: 2; }
}

footer {
    display: flex; justify-content: space-between; gap: 16px; padding-top: 32px; padding-bottom: 40px;
    color: var(--muted); font-size: 13px;
}
footer a { color: var(--muted); }

/* ---- the profile (an "about me" page) ---- */

.profile { display: flex; align-items: center; gap: 28px; padding: 48px 0 24px; }
.photo {
    flex: none; width: 160px; height: 160px; border-radius: 50%;
    object-fit: cover; object-position: 48% 30%;
    border: 4px solid var(--surface); box-shadow: 0 6px 24px rgba(16, 24, 40, 0.15);
}
.profile h1 { margin: 0 0 6px; }
.headline { margin: 0; font-size: 17px; }
.place { margin: 4px 0 14px; color: var(--muted); font-size: 14px; }
.button {
    display: inline-block; padding: 9px 18px; border-radius: 999px;
    background: var(--accent); color: var(--surface); font-weight: 600; font-size: 14px; text-decoration: none;
}
.button:hover { opacity: 0.9; }

.prose p { margin: 0 0 10px; color: var(--text); font-size: 15px; }
.prose p:last-child { margin-bottom: 0; }

.timeline { padding: 4px 20px; }
.job { padding: 18px 0; border-top: 1px solid var(--line); }
.job:first-child { border-top: 0; }
.job h3 { margin: 0; font-size: 16px; }
.org { margin: 2px 0 0; font-weight: 600; font-size: 15px; }
.org_first { margin: 0; font-size: 16px; }
.when { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.job ul { margin: 10px 0 0; padding-left: 18px; color: var(--muted); font-size: 14.5px; }
.job li { margin-bottom: 4px; }
.role { margin: 14px 0 0 0; padding-left: 14px; border-left: 2px solid var(--line); }
.role ul { margin-top: 6px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips span { padding: 5px 12px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 600; }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.list > * { margin: 0 0 10px; }
.list > *:last-child { margin-bottom: 0; }
.list h3 { margin: 0; font-size: 15px; }
.list p { margin: 0; color: var(--muted); font-size: 14px; }
.list > p { color: var(--text); }

.languages { display: flex; flex-wrap: wrap; gap: 28px; }
.languages div { display: flex; flex-direction: column; }
.languages span { color: var(--muted); font-size: 13px; }

.footer_links { display: flex; gap: 16px; }

@media (max-width: 680px) {
    .profile { flex-direction: column; text-align: center; padding-top: 28px; }
    .two { grid-template-columns: 1fr; }
}

/* ---- status dropdown (top right) ---- */

.top { position: relative; z-index: 5; }
.status_menu { position: relative; }
button.status_link {
    padding: 0; border: 0; background: none; cursor: pointer;
    color: var(--muted); font: inherit; font-size: 15px; font-weight: 600;
}
button.status_link:hover, button.status_link[aria-expanded="true"] { color: var(--text); }
.caret { font-size: 11px; }

.status_panel {
    position: absolute; right: 0; top: calc(100% + 10px); width: min(340px, calc(100vw - 32px));
    padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface);
    box-shadow: 0 12px 32px rgba(16, 24, 40, 0.18);
}
.status_panel[hidden] { display: none; }
.status_summary { margin: 0 0 8px; font-weight: 600; font-size: 14px; }
.status_panel .status_row {
    display: flex; justify-content: space-between; align-items: center; gap: 12px;
    padding: 9px 4px; border-top: 1px solid var(--line); color: var(--text); text-decoration: none; font-size: 14px;
}
.status_panel .status_row:hover { background: var(--accent-soft); }
.status_note { margin: 8px 0 0; color: var(--muted); font-size: 12px; }
