:root {
    --bg: #f5f6f3;
    --surface: #ffffff;
    --surface-soft: #eef2ed;
    --text: #18211d;
    --muted: #66706a;
    --line: #dfe5df;
    --accent: #2e6149;
    --accent-dark: #204735;
    --accent-soft: #e4f0e9;
    --warm-soft: #f3eee3;
    --warm-text: #715c31;
    --shadow: 0 12px 30px rgba(30, 46, 38, 0.06);
    --radius: 18px;
    --shell: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

svg {
    width: 1em;
    height: 1em;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex: 0 0 auto;
}

.shell {
    width: min(calc(100% - 40px), var(--shell));
    margin-inline: auto;
}

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 100;
    padding: 10px 14px;
    background: var(--text);
    color: white;
    border-radius: 10px;
    transform: translateY(-160%);
    transition: transform .2s ease;
}

.skip-link:focus { transform: translateY(0); }

.site-header {
    border-bottom: 1px solid rgba(223, 229, 223, .85);
    background: rgba(245, 246, 243, .9);
    backdrop-filter: blur(14px);
    position: sticky;
    top: 0;
    z-index: 20;
}

.header-inner {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    gap: 10px;
    align-items: baseline;
    text-decoration: none;
}

.brand-name { font-weight: 760; letter-spacing: -.02em; }
.brand-label { color: var(--muted); font-size: .9rem; }

.profile-links {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    font-size: .9rem;
}

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

.profile-links a:hover,
.profile-links a:focus-visible { color: var(--accent); }

.hero {
    padding: 78px 0 56px;
    background:
        radial-gradient(circle at 82% 12%, rgba(46, 97, 73, .10), transparent 31%),
        linear-gradient(180deg, #f8f9f6 0%, var(--bg) 100%);
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(300px, .75fr);
    gap: 54px;
    align-items: end;
}

.eyebrow {
    margin: 0 0 9px;
    color: var(--accent);
    font-size: .78rem;
    font-weight: 750;
    letter-spacing: .12em;
    text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
    margin-bottom: 14px;
    max-width: 760px;
    font-size: clamp(2.8rem, 7vw, 5.6rem);
    line-height: .98;
    letter-spacing: -.055em;
    font-weight: 760;
}

.hero-subtitle {
    margin-bottom: 15px;
    color: var(--accent-dark);
    font-size: clamp(1.15rem, 2vw, 1.45rem);
    font-weight: 620;
    letter-spacing: -.02em;
}

.hero-intro {
    max-width: 710px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 1.05rem;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--line);
    box-shadow: var(--shadow);
}

.metric {
    min-width: 0;
    padding: 22px 17px;
    background: rgba(255,255,255,.92);
}

.metric-value {
    display: block;
    font-size: clamp(1.55rem, 3vw, 2.2rem);
    line-height: 1;
    font-weight: 760;
    letter-spacing: -.04em;
}

.metric-label {
    display: block;
    margin-top: 7px;
    color: var(--muted);
    font-size: .78rem;
}

.metric-note {
    grid-column: 1 / -1;
    margin: 0;
    padding: 9px 14px;
    background: var(--surface);
    color: var(--muted);
    font-size: .72rem;
    text-align: right;
}

.publication-section { padding: 54px 0 84px; }

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 22px;
    margin-bottom: 24px;
}

.section-heading h2 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3.1rem);
    letter-spacing: -.045em;
    line-height: 1;
}

.result-count {
    margin: 0;
    color: var(--muted);
    font-size: .9rem;
}

.filters {
    display: grid;
    grid-template-columns: minmax(250px, 1fr) auto auto auto auto;
    gap: 10px;
    align-items: center;
    margin-bottom: 22px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255,255,255,.68);
}

.search-field {
    position: relative;
    display: flex;
    align-items: center;
}

.search-field svg {
    position: absolute;
    left: 14px;
    color: var(--muted);
    pointer-events: none;
}

input[type="search"],
select {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--line);
    border-radius: 11px;
    background: var(--surface);
    color: var(--text);
    font: inherit;
    font-size: .9rem;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}

input[type="search"] { padding: 9px 13px 9px 41px; }
select { padding: 9px 34px 9px 12px; }

input[type="search"]:focus,
select:focus {
    border-color: rgba(46, 97, 73, .58);
    box-shadow: 0 0 0 3px rgba(46, 97, 73, .10);
}

.clear-filters {
    min-height: 44px;
    padding: 8px 13px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-size: .86rem;
    cursor: pointer;
}

.clear-filters:hover,
.clear-filters:focus-visible {
    background: var(--surface-soft);
    color: var(--text);
}

.publication-list {
    display: grid;
    gap: 12px;
}

.publication-card {
    padding: 27px 29px 25px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 1px 0 rgba(30,46,38,.02);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.publication-card:hover {
    transform: translateY(-1px);
    border-color: #ccd7ce;
    box-shadow: var(--shadow);
}

.publication-card[hidden] { display: none; }

.publication-topline { margin-bottom: 13px; }

.badges {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 680;
    line-height: 1;
    white-space: nowrap;
}

.badge svg { width: 12px; height: 12px; }
.badge-neutral { background: #eef0ee; color: #53605a; }
.badge-year { background: #f4f4f0; color: #6a6b63; }
.badge-open { background: var(--accent-soft); color: var(--accent-dark); }
.badge-appendix { background: var(--warm-soft); color: var(--warm-text); }

.publication-title {
    margin: 0 0 9px;
    max-width: 930px;
    font-size: clamp(1.18rem, 2vw, 1.42rem);
    line-height: 1.3;
    letter-spacing: -.025em;
    font-weight: 710;
}

.publication-title a {
    text-decoration: none;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

.publication-title a:hover,
.publication-title a:focus-visible {
    color: var(--accent-dark);
    text-decoration: underline;
}

.authors,
.venue {
    margin-bottom: 5px;
    color: var(--muted);
    font-size: .92rem;
}

.venue { margin-bottom: 0; }

.publication-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 19px;
}

.action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 36px;
    padding: 7px 11px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fbfcfa;
    color: #445049;
    text-decoration: none;
    font-size: .8rem;
    font-weight: 620;
    line-height: 1.2;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}

.action svg { width: 14px; height: 14px; }

.action:hover,
.action:focus-visible {
    border-color: #c3d0c6;
    background: var(--surface-soft);
    color: var(--accent-dark);
}

.action-primary {
    border-color: var(--accent);
    background: var(--accent);
    color: white;
}

.action-primary:hover,
.action-primary:focus-visible {
    border-color: var(--accent-dark);
    background: var(--accent-dark);
    color: white;
}

.action-static { cursor: default; }

.empty-state {
    padding: 62px 24px;
    border: 1px dashed #cbd5cd;
    border-radius: var(--radius);
    text-align: center;
    color: var(--muted);
}

.empty-state h3 { margin-bottom: 7px; color: var(--text); }
.empty-state p { margin-bottom: 18px; }
.empty-state .action { border: 0; cursor: pointer; font: inherit; font-size: .85rem; }

.site-footer {
    border-top: 1px solid var(--line);
    background: #eff1ed;
}

.footer-inner {
    min-height: 92px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    color: var(--muted);
    font-size: .8rem;
}

.footer-inner p { margin: 0; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 900px) {
    .hero { padding-top: 54px; }
    .hero-grid { grid-template-columns: 1fr; gap: 34px; }
    .metrics { max-width: 650px; }
    .filters { grid-template-columns: 1fr 1fr; }
    .search-field { grid-column: 1 / -1; }
    .clear-filters { justify-self: start; }
}

@media (max-width: 620px) {
    .shell { width: min(calc(100% - 26px), var(--shell)); }
    .site-header { position: static; }
    .header-inner { min-height: 62px; }
    .profile-links { display: none; }
    .hero { padding: 46px 0 38px; }
    h1 { font-size: clamp(2.6rem, 15vw, 4.2rem); }
    .metrics { grid-template-columns: repeat(3, 1fr); }
    .metric { padding: 17px 11px; }
    .metric-value { font-size: 1.45rem; }
    .metric-label { font-size: .68rem; }
    .publication-section { padding-top: 42px; }
    .section-heading { align-items: start; }
    .filters { grid-template-columns: 1fr; }
    .search-field { grid-column: auto; }
    .publication-card { padding: 22px 20px 21px; }
    .publication-actions { gap: 7px; }
    .action { flex: 1 1 auto; }
    .footer-inner { padding: 22px 0; display: block; }
    .footer-inner p + p { margin-top: 5px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
