/* BASE LAYOUT: page width, navigation, sections, cards, map and responsive rules.
   Shared theme values belong in theme.css; typography belongs in design-system.css. */

:root {
    color-scheme: light;
}

* {
    box-sizing: border-box
}

html {
    scroll-behavior: smooth
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
}

a {
    color: inherit
}

.wrap {
    width: min(var(--page), calc(100% - 64px));
    margin: auto
}

.skip {
    position: absolute;
    left: -9999px;
    top: 8px;
    background: var(--bg);
    padding: 10px
}

.skip:focus {
    left: 12px;
    z-index: 3
}

.top {
    height: 78px;
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: space-between
}

.brand {
    text-decoration: none;
}

.brand span {
    color: var(--accent)
}

.top nav {
    display: flex;
    gap: 28px;
}

.top nav a {
    text-decoration: none
}

.top nav a:hover,
.top nav a:focus {
    text-decoration: underline;
    text-underline-offset: 5px
}

.hero {
    padding: 76px 0 88px;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    align-items: center;
    gap: 64px
}

.eyebrow,
.kicker {
    color: var(--accent)
}

h1 {
    margin: 18px 0 26px;
    max-width: 720px
}

.lede {
    max-width: 590px;
    color: var(--muted);
}

.actions {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.button {
    text-decoration: none;
    background: var(--accent);
    color: var(--bg);
    padding: 13px 18px;
    border-radius: var(--button-radius)
}

.text-link {
    text-underline-offset: 4px
}

.hero-art {
    position: relative;
    margin: 0;
    background: var(--panel);
    padding: 0;
    overflow: hidden
}

.hero-art img {
    width: 100%;
    height: 430px;
    object-fit: cover;
    display: block
}

figcaption,
.hero-art small,
.photo-note {
    display: block;
    padding: 10px 12px;
    color: var(--muted);
}

.divider {
    border-top: 1px solid var(--line)
}

.section {
    padding: var(--section-top) 0 var(--section-bottom)
}

.section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    margin-bottom: 28px
}

.section-head h2 {
    margin: 0
}

.section-head p {
    color: var(--muted);
    margin: 0;
    max-width: 390px;
}

.projects {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: var(--line);
    border: 1px solid var(--line)
}

.project {
    background: var(--bg);
    padding: 28px;
    min-height: 218px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-decoration: none
}

.project:hover .project-title {
    color: var(--accent)
}

.number {
    color: var(--accent);
}

.project-title {
    margin: 14px 0 8px
}

.project p {
    color: var(--muted);
    margin: 0;
    max-width: 490px
}

.arrow {
    align-self: flex-end;
    color: var(--accent)
}

.metrics {
    display: flex;
    gap: 48px;
    padding: 34px 0 8px
}

.metric strong {
    display: block;
    color: var(--accent);
}

.metric span {
    color: var(--muted)
}

.media-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    align-items: start
}

.media-grid figure {
    margin: 0
}

.media-grid img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
    background: var(--panel)
}

.media-grid figcaption {
    padding: 10px 0;
    color: var(--muted);
}

.media-grid figcaption a {
    color: var(--ink);
    text-underline-offset: 3px
}

.media-more {
    margin: 24px 0 0;
    max-width: 760px;
    color: var(--muted);
}

.about {
    display: grid;
    grid-template-columns: .65fr 1.35fr;
    gap: 60px;
    align-items: start
}

.about h2 {
    margin: 0
}

.about p {
    color: var(--muted);
    max-width: 680px;
    margin: 0
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 23px
}

.tags span {
    border: 1px solid var(--line);
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--muted)
}

.contact {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    background: var(--panel);
    padding: 34px 38px
}

.contact h2 {
    margin: 0
}

.contact p {
    margin: 8px 0 0;
    color: var(--muted);
}

footer {
    padding: 32px 0 46px;
    color: var(--muted);
    display: flex;
    justify-content: space-between
}

.index-art {
    padding: 20px;
    background: var(--panel)
}

.index-art img {
    height: 385px
}

.stamp {
    position: absolute;
    left: 0;
    top: 42px;
    background: var(--accent);
    color: var(--bg);
    padding: 19px 22px;
}

.field-art img {
    height: 460px;
    filter: saturate(.78)
}

.field-art:after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 55%, var(--overlay-soft))
}

.photo-note {
    position: relative;
    z-index: 1;
    background: var(--panel)
}

.button {
    color: var(--bg)
}

@media(max-width:760px) {
    .wrap {
        width: calc(100% - 38px)
    }

    .top {
        height: auto;
        min-height: 70px;
        align-items: flex-start;
        padding: 19px 0;
        gap: 16px;
        flex-direction: column
    }

    .top nav {
        gap: 18px;
        overflow-x: auto;
        max-width: 100%;
        padding-bottom: 2px;
    }

    .hero {
        grid-template-columns: 1fr;
        gap: 34px;
        padding: 50px 0 56px
    }

    h1 {
        max-width: 600px
    }

    .hero-art img {
        height: 300px
    }

    .section {
        padding: 46px 0 54px
    }

    .section-head {
        display: block
    }

    .section-head p {
        margin-top: 12px
    }

    .projects {
        grid-template-columns: 1fr
    }

    .project {
        min-height: 185px;
        padding: 23px
    }

    .metrics {
        gap: 20px;
        justify-content: space-between
    }

    .media-grid {
        grid-template-columns: 1fr;
        gap: 18px
    }

    .media-more {
        margin-top: 18px
    }

    .about {
        grid-template-columns: 1fr;
        gap: 20px
    }

    .contact {
        align-items: flex-start;
        flex-direction: column;
        padding: 26px
    }

    footer {
        gap: 12px;
        flex-direction: column
    }

    .index-art img {
        height: 300px
    }

    .field-art img {
        height: 330px
    }
}

@media(prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto
    }

    * {
        transition: none !important
    }
}

:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 5px
}

section[id],
article[id],
#cv {
    scroll-margin-top: 28px
}

.case-study {
    display: grid;
    grid-template-columns: .85fr 1.15fr;
    gap: 70px;
    padding: 48px 0;
    border-top: 1px solid var(--line)
}

.case-heading h3 {
    margin: 16px 0
}

.case-intro {
    color: var(--muted)
}

.back-link {
    display: inline-block;
    margin-top: 16px;
}

.case-body {
    color: var(--muted)
}

.case-body h4 {
    color: var(--ink);
    margin: 24px 0 8px
}

.case-body h4:first-child {
    margin-top: 0
}

.case-body p {
    margin: 0 0 18px
}

.case-note {
    border-left: 2px solid var(--line);
    padding: 8px 0 8px 16px;
}

.cv-note {
    max-width: 340px;
    scroll-margin-top: 30px
}

.cv-note h3 {
    margin: 0;
}

.contact {
    align-items: start
}

.contact>div:first-child {
    max-width: 570px
}

.project:focus-visible .project-title {
    color: var(--accent)
}

@media(max-width:760px) {
    .case-study {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 34px 0
    }

    .actions {
        flex-wrap: wrap
    }

    .metrics {
        flex-wrap: wrap
    }

    .contact {
        gap: 28px
    }
}

/* Project pages retain the approved Concept A palette and typography. */
.project {
    padding: 0;
    overflow: hidden;
    justify-content: start
}

.project .card-image {
    width: 100%;
    height: 250px;
    object-fit: contain;
    background: var(--panel);
    border-bottom: 1px solid var(--line)
}

.project .card-image.document {
    object-fit: cover;
    object-position: top
}

.card-copy {
    padding: 25px 28px;
    flex: 1
}

.project .arrow {
    padding: 0 28px 20px
}

.project .number {
    display: block
}

.project-title {
    margin-top: 12px
}

.projects {
    gap: 22px;
    background: transparent;
    border: 0
}

.project {
    border: 1px solid var(--line)
}

.project:last-child:nth-child(odd) {
    grid-column: 1/-1;
    display: grid;
    grid-template-columns: 1fr 1fr
}

.project:last-child:nth-child(odd) .card-image {
    height: 100%;
    grid-row: 1/3;
    border-bottom: 0;
    border-right: 1px solid var(--line)
}

.project:last-child:nth-child(odd) .arrow {
    justify-self: end
}

.hero-art img {
    object-fit: contain;
    height: auto
}

.top nav {
    flex-wrap: wrap
}

.actions {
    flex-wrap: wrap
}

.breadcrumb {
    padding-top: 30px;
}

.breadcrumb a {
    text-underline-offset: 4px
}

.story-hero {
    padding: 44px 0 48px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: center
}

.story-hero h1 {
    margin: 16px 0 22px;
}

.story-hero figure {
    margin: 0;
    background: var(--panel)
}

.story-hero img {
    width: 100%;
    height: auto;
    max-height: 480px;
    object-fit: contain;
    display: block
}

.project-facts {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    gap: 30px;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 22px 0;
    margin-bottom: 55px;
}

.project-facts dt {
    color: var(--accent);
    margin-bottom: 7px
}

.project-facts dd {
    margin: 0
}

.story-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 64px;
    align-items: start;
    padding-bottom: 70px
}

.story-menu {
    position: sticky;
    top: 24px;
}

.story-menu>a {
    display: block;
    margin: 0 0 12px;
    text-underline-offset: 4px
}

.story-menu .quote {
    margin: 34px 0 0;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.story-copy {
    max-width: 740px
}

.story-copy h2 {
    margin: 0 0 18px
}

.story-copy section+section {
    margin-top: 38px
}

.story-copy p {
    color: var(--ink);
    margin: 0 0 18px
}

.resources {
    padding: 55px 0 70px
}

.resource-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px
}

.resource {
    margin: 0;
    border: 1px solid var(--line);
    background: var(--bg);
    display: flex;
    flex-direction: column;
    min-width: 0
}

.resource-visual {
    position: relative;
    display: block;
    background: var(--panel);
    overflow: hidden
}

.resource img {
    width: 100%;
    height: 285px;
    object-fit: contain;
    display: block
}

.resource.document img {
    object-fit: cover;
    object-position: top
}

.resource .play {
    position: absolute;
    right: 16px;
    bottom: 16px;
    background: var(--accent);
    color: var(--bg);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
}

.resource figcaption {
    padding: 23px 25px;
    flex: 1;
}

.resource h3 {
    color: var(--ink);
    margin: 9px 0 12px
}

.resource p {
    margin: 0 0 14px;
    color: var(--muted)
}

.resource .resource-type {
    color: var(--accent);
}

.resource .credit {
    display: block;
    color: var(--muted);
    margin-top: 15px
}

.resource-link {
    text-underline-offset: 4px
}

.review-label {
    border-left: 2px solid var(--accent);
    padding: 10px 15px;
    color: var(--muted);
    margin: 20px 0 28px;
    max-width: 800px
}

.review-notes {
    margin-top: 30px;
    border: 1px solid var(--line);
    padding: 18px 22px;
    max-width: 900px;
    color: var(--muted)
}

.review-notes summary {
    cursor: pointer;
    color: var(--ink)
}

.next-project {
    padding: 35px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 25px;
    border-top: 1px solid var(--line);
}

.next-project a {
    text-underline-offset: 5px
}

.project-local {
    color: var(--muted)
}

.flow-inline {
    margin: 30px 0
}

.flow-inline img {
    width: 100%;
    height: auto
}

.flow-inline figcaption {
    padding-left: 0
}

.top a,
.resource a {
    overflow-wrap: anywhere
}

@media(max-width:760px) {
    .story-hero {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-top: 28px
    }

    .project-facts {
        grid-template-columns: 1fr;
        gap: 17px;
        margin-bottom: 34px
    }

    .story-layout {
        grid-template-columns: 1fr;
        gap: 25px;
        padding-bottom: 40px
    }

    .story-menu {
        position: static;
        display: flex;
        gap: 20px;
        flex-wrap: wrap
    }

    .story-menu .quote {
        display: none
    }

    .resource-grid {
        grid-template-columns: 1fr
    }

    .resource img {
        height: auto;
        max-height: 340px
    }

    .resource.document img {
        height: 300px
    }

    .project .card-image {
        height: 220px
    }

    .project:last-child:nth-child(odd) {
        display: flex;
        grid-column: auto
    }

    .project:last-child:nth-child(odd) .card-image {
        height: 220px;
        border-right: 0
    }

    .next-project {
        align-items: start;
        flex-direction: column
    }

    .resources {
        padding-top: 38px
    }

    .resource figcaption {
        padding: 20px
    }

    .top nav {
        gap: 16px
    }
}

/* Original previews: display crops exclude measured black bands without modifying source files. */
.poster-window {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: var(--poster-ratio, 1.777778);
    overflow: hidden;
    background: var(--panel)
}

.poster-window img {
    position: absolute !important;
    left: 0;
    width: 100% !important;
    max-height: none !important;
    object-fit: fill !important;
    margin: 0;
    display: block
}

.resource .poster-window,
.project .poster-window.card-image {
    height: auto;
    aspect-ratio: var(--poster-ratio, 1.777778)
}

.project:last-child:nth-child(odd) .poster-window.card-image {
    height: auto;
    align-self: center
}

.source-link {
    display: block;
    margin-top: 12px;
    text-underline-offset: 4px;
    color: var(--ink)
}

.resource-group {
    margin-top: 52px
}

.resource-group>h2 {
    margin: 0 0 25px
}

.media-intro {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 60px;
    padding: 70px 0 75px
}

.media-intro figure {
    margin: 0
}

.media-intro figcaption {
    padding-left: 0;
}

.media-intro-links {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    margin-top: 28px;
    text-underline-offset: 4px
}

.collection-links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px
}

.collection-links>a {
    display: block;
    padding: 25px;
    border-top: 1px solid var(--line);
    text-decoration: none
}

.collection-links>a:hover {
    background: var(--panel)
}

.collection-links span {
    color: var(--accent)
}

.collection-links h3 {
    margin: 15px 0
}

.collection-links p {
    color: var(--muted);
    margin: 0
}

.media-filters,
.map-filters,
.map-views {
    display: flex;
    gap: 10px;
    flex-wrap: wrap
}

.media-filters button,
.map-filters button,
.map-views button {
    border: 1px solid var(--line);
    color: var(--ink);
    background: var(--bg);
    padding: 11px 15px;
    cursor: pointer;
    border-radius: var(--button-radius);
    min-height: 42px
}

.media-filters button[aria-pressed=true],
.map-filters button[aria-pressed=true],
.map-views button[aria-pressed=true] {
    color: var(--bg);
    background: var(--ink);
    border-color: var(--ink)
}

.result-count {
    color: var(--muted);
    margin: 20px 0
}

[hidden] {
    display: none !important
}

.photo-resource .resource-visual img {
    height: 310px;
    object-fit: contain;
    background: var(--panel)
}

.multimedia-teaser {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 60px
}

.multimedia-teaser h2 {
    margin: 15px 0 20px
}

.multimedia-teaser p:not(.kicker) {
    color: var(--muted);
    max-width: 530px;
    margin-bottom: 30px
}

.multimedia-teaser .button {
    display: inline-block;
}

.teaser-image img {
    width: 100%;
    display: block
}

.assignment-map {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    border: 1px solid var(--line);
    margin-top: 22px;
    background: var(--panel)
}

.map-canvas {
    position: relative;
    min-width: 0;
    align-self: start
}

.map-water {
    fill: var(--bg)
}

.map-countries path {
    fill: var(--panel);
    stroke: var(--bg);
    stroke-width: .9;
    vector-effect: non-scaling-stroke
}

#work-map {
    width: 100%;
    height: auto;
    display: block;
    min-height: 400px
}

.map-views {
    padding: 17px 17px 0
}

.map-views button {
    padding: 7px 11px;
    min-height: 36px
}

.map-marker {
    cursor: pointer;
    outline: none
}

.pin-hit {
    fill: transparent;
    stroke: none
}

.pin-shape {
    fill: var(--accent);
    stroke: var(--bg);
    stroke-width: 2;
    vector-effect: non-scaling-stroke
}

.pin-base .pin-shape {
    fill: var(--ink)
}

.pin-field .pin-shape {
    fill: var(--ink)
}

.map-marker.is-active .pin-shape,
.map-marker:focus-visible .pin-shape {
    stroke: var(--ink);
    stroke-width: 3;
    filter: drop-shadow(0 1px 3px var(--bg))
}

.pin-label {
    display: none;
    fill: var(--ink);
    paint-order: stroke;
    stroke: var(--bg);
    stroke-width: 4px;
    stroke-linejoin: round;
    pointer-events: none
}

.map-marker.is-active .pin-label,
.map-marker:focus-visible .pin-label {
    display: block
}

.map-key {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    color: var(--ink);
    padding: 0 20px 12px
}

.map-attribution {
    padding: 0 20px 16px;
    color: var(--muted);
    margin: 0
}

.map-information {
    background: var(--bg);
    padding: 24px;
    border-left: 1px solid var(--line);
    min-width: 0
}

#map-detail .kicker {
    margin: 0 0 10px
}

#map-detail h3 {
    margin: 0 0 7px
}

#map-detail h4 {
    margin: 15px 0 7px
}

#map-detail p:not(.kicker) {
    color: var(--muted);
    margin: 0 0 12px
}

.map-detail-image {
    width: 100%;
    height: 145px;
    object-fit: contain;
    display: block;
    background: var(--panel)
}

.map-detail-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 17px 0 22px;
}

.map-list-label {
    color: var(--muted);
    border-top: 1px solid var(--line);
    padding-top: 18px;
    margin: 0 0 10px
}

.map-list {
    max-height: 225px;
    overflow: auto;
    scrollbar-width: thin
}

.assignment-option {
    display: flex;
    width: 100%;
    justify-content: space-between;
    text-align: left;
    gap: 12px;
    border: 0;
    border-bottom: 1px solid var(--line);
    background: transparent;
    padding: 11px 5px;
    color: var(--ink);
    cursor: pointer;
    min-height: 44px
}

.assignment-option small {
    color: var(--muted);
    max-width: 115px
}

.assignment-option[aria-pressed=true] {
    background: var(--panel);
    padding-left: 9px
}

.map-footnote {
    color: var(--muted);
    margin: 17px 0 0;
    max-width: 850px
}

@media(max-width:900px) {
    .assignment-map {
        grid-template-columns: 1fr
    }

    .map-information {
        border-left: 0;
        border-top: 1px solid var(--line);
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0 30px
    }

    .map-information #map-detail {
        grid-row: 1/3
    }

    .map-list-label {
        padding-top: 0;
        border: 0
    }

    .map-list {
        max-height: 340px
    }

    #work-map {
        min-height: 0
    }
}

@media(max-width:760px) {

    .media-intro,
    .multimedia-teaser {
        grid-template-columns: 1fr;
        gap: 30px;
        padding-top: 45px
    }

    .collection-links {
        grid-template-columns: 1fr
    }

    .collection-links>a {
        padding: 22px 0
    }

    .photo-resource .resource-visual img {
        height: auto
    }

    .map-filters {
        gap: 7px
    }

    .map-filters button {
        padding: 9px 11px;
    }

    .map-information {
        display: block;
        padding: 22px
    }

    .map-list {
        max-height: 200px
    }

    .map-detail-image {
        height: 180px
    }

    .map-list-label {
        border-top: 1px solid var(--line);
        padding-top: 18px
    }

    .map-key {
        gap: 15px;
        padding-left: 12px
    }

    .map-attribution {
        padding-left: 12px
    }

    .map-views {
        padding: 12px 12px 0
    }

    .map-countries path {
        stroke-width: .7
    }

    .poster-window {
        max-height: none
    }

    .resource .poster-window {
        max-height: none
    }

    .multimedia-teaser {
        padding-bottom: 45px
    }
}

@media(max-width:760px) {}

/* Prominent professional identity and verified membership/course credentials. */
.top {
    height: auto;
    min-height: 100px;
    padding: 20px 0;
    gap: 24px;
    flex-wrap: wrap
}

.brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    text-decoration: none
}

.brand .brand-name {
    white-space: nowrap;
    color: var(--ink)
}

.brand .brand-name>span {
    color: var(--accent)
}

.brand .postnominal {
    margin-left: .75em;
    color: var(--ink)
}

.brand .brand-tagline {
    color: var(--muted)
}

.top nav {
    margin-left: auto
}

.membership-panel {
    display: flex;
    gap: 32px;
    align-items: center;
    background: var(--panel);
    padding: 28px 32px;
    margin: 0 0 24px
}

.membership-mark {
    color: var(--accent)
}

.membership-panel h3 {
    margin: 0 0 8px
}

.membership-panel p {
    color: var(--muted);
    margin: 0
}

.credential-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px
}

.credential {
    border-top: 1px solid var(--line);
    padding: 23px 0 15px
}

.credential .credential-issuer {
    color: var(--accent);
    margin: 0 0 12px
}

.credential h3 {
    margin: 0 0 13px;
    max-width: 490px
}

.credential>p:not(.credential-issuer) {
    color: var(--muted);
    margin: 0 0 7px
}

.education-block {
    border-top: 1px solid var(--line);
    margin-top: 25px;
    padding-top: 25px
}

.education-block>h3 {
    margin: 0 0 22px
}

.education-block ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px
}

.education-block strong {
    display: block
}

.education-block span {
    color: var(--muted);
    display: block
}

.about .credentials-jump {
    margin-top: 20px
}

#credentials {
    scroll-margin-top: 25px
}

@media(max-width:760px) {
    .top {
        padding: 21px 0;
        gap: 18px;
        min-height: 0
    }

    .top nav {
        margin-left: 0;
        gap: 17px
    }

    .membership-panel {
        align-items: flex-start;
        flex-direction: column;
        gap: 18px;
        padding: 25px
    }

    .credential-grid,
    .education-block ul {
        grid-template-columns: 1fr;
        gap: 16px
    }
}
