:root {
    --bg: #d9f1fb;
    --bg2: #f7fcff;
    --ink: #102a43;
    --muted: #526b7a;
    --line: #b5d5e2;
    --accent: #087f8c;
    --accent2: #ef7d62;
    --accent-soft: #d7f0f2;
    --card: #f8fcfd;
    --display: 'Newsreader', Georgia, serif;
    --body: 'Inter', system-ui, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    text-wrap: balance;
}

p,
li,
blockquote,
dd {
    text-align: justify;
    text-align-last: left;
    text-justify: inter-word;
    text-wrap: pretty;
    hyphens: auto;
    overflow-wrap: break-word;
}

@media (max-width: 700px) {
    p,
    li,
    blockquote,
    dd {
        text-align: left;
    }
}

body {
    background: var(--bg);
    color: var(--ink);
    font-family: var(--body);
    line-height: 1.65;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    transition: background .4s, color .4s;
    min-height: 100vh;
    background-color: var(--bg);
    background-image:
        linear-gradient(rgba(8, 127, 140, .055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(8, 127, 140, .055) 1px, transparent 1px),
        radial-gradient(circle at 12% 8%, rgba(255, 255, 255, .72), transparent 30%),
        radial-gradient(circle at 88% 82%, rgba(239, 125, 98, .1), transparent 26%);
    background-size: 32px 32px, 32px 32px, auto, auto;
    background-attachment: fixed;
    animation: bg-breathe 24s ease-in-out infinite alternate;
}

/* Cinema-roll bands on main page (top + bottom) */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 120px;
    z-index: 50;
    background-image: url('documents/portfolio image.png');
    background-size: auto 100%;
    background-repeat: repeat-x;
    animation: bandScrollRight 30s linear infinite;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    z-index: 50;
    background-image: url('documents/portfolio image.png');
    background-size: auto 100%;
    background-repeat: repeat-x;
    animation: bandScrollLeft 30s linear infinite;
    mask-image: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    pointer-events: none;
}

@keyframes bg-breathe {
    0% {
        background-color: #d9f1fb;
    }
    25% {
        background-color: #d4ecf8;
    }
    50% {
        background-color: #dceef7;
    }
    75% {
        background-color: #d7edf5;
    }
    100% {
        background-color: #ddf0f9;
    }
}

a {
    color: inherit;
}

@media (hover: hover) and (pointer: fine) {
    body {
        cursor: none;
    }

    body,
    body * {
        cursor: none !important;
    }

    .arrow-cur {
        position: fixed;
        top: 0;
        left: 0;
        z-index: 10010;
        pointer-events: none;
        filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .4));
    }

    .cur {
        position: fixed;
        top: 0;
        left: 0;
        width: 24px;
        height: 24px;
        border-radius: 50%;
        pointer-events: none;
        z-index: 10009;
        transform: translate(-50%, -50%);
        background: color-mix(in srgb, var(--accent) 10%, transparent);
        border: 1px solid color-mix(in srgb, var(--accent) 80%, transparent);
        box-shadow: 0 0 0 1px rgba(255, 255, 255, .04), 0 0 18px color-mix(in srgb, var(--accent) 16%, transparent);
        transition: width .25s, height .25s, background .25s, border-color .25s;
    }

    .cur::after {
        content: '';
        position: absolute;
        inset: 5px;
        border-radius: 50%;
        background: color-mix(in srgb, var(--accent) 70%, transparent);
        opacity: .8;
    }

    .cur .lbl {
        position: absolute;
        left: 50%;
        top: 110%;
        transform: translateX(-50%);
        font-size: 9px;
        font-weight: 600;
        letter-spacing: .1em;
        text-transform: uppercase;
        color: var(--accent);
        background: var(--bg);
        padding: 2px 7px;
        border-radius: 10px;
        white-space: nowrap;
        opacity: 0;
        transition: opacity .2s;
    }

    body.hovering .cur {
        width: 44px;
        height: 44px;
        background: color-mix(in srgb, var(--accent) 18%, transparent);
    }

    body.hovering .cur::after {
        inset: 9px;
        opacity: 1;
    }

    body.hovering .cur .lbl {
        opacity: 1;
    }
}

.topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 26px;
    z-index: 60;
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
}

.topbar .left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.home-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    background-size: cover;
    background-position: 50% 18%;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
    transition: transform .2s;
    display: block;
}

.home-btn:hover {
    transform: scale(1.07);
}

.wordmark {
    font-family: var(--display);
    font-size: 1.1rem;
    font-weight: 500;
}

.wordmark span {
    display: block;
    font-family: var(--body);
    font-size: .58rem;
    font-weight: 500;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--accent);
    margin-top: 2px;
}

.topbar .right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.icon-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 40px;
    padding: 0 16px;
    border-radius: 30px;
    border: 1px solid var(--line);
    background: var(--card);
    color: var(--ink);
    text-decoration: none;
    font-size: .82rem;
    font-weight: 500;
    transition: border-color .2s, transform .2s;
}

.icon-btn:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.icon-btn svg {
    width: 16px;
    height: 16px;
}

.icon-btn.solid {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.icon-btn.solid,
.btn,
.btn-sm {
    box-shadow: 0 8px 18px rgba(8, 127, 140, .18);
}

@media (max-width:720px) {
    .icon-btn .t {
        display: none;
    }

    .icon-btn {
        padding: 0 12px;
    }

    .wordmark span {
        display: none;
    }
}

.split {
    display: grid;
    grid-template-columns: 0.3fr 1.3fr 0.9fr;
    gap: 0;
    min-height: 100vh;
    padding-top: 74px;
}

@media (max-width:880px) {
    .split {
        grid-template-columns: 1fr;
    }
}

.worldmap {
    display: block;
    width: 100%;
    height: auto;
    filter: grayscale(1) contrast(.82);
    opacity: .72;
}

.map-panel {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 640px;
    margin: 0 auto 30px;
}

.map-title {
    margin-bottom: 14px;
    color: var(--ink);
    font-family: var(--display);
    font-size: clamp(1.35rem, 2.6vw, 1.8rem);
    font-weight: 500;
    line-height: 1.1;
}

.map-stage {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: color-mix(in srgb, var(--card) 55%, transparent);
    border: 1px solid var(--line);
}

.map-pin {
    position: absolute;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent2);
    border: 2px solid var(--accent);
    box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent2) 24%, transparent);
    transform: translate(-50%, -50%);
}

.map-pin::after {
    content: '';
    position: absolute;
    inset: -7px;
    border: 1px solid var(--accent2);
    border-radius: 50%;
    opacity: .45;
    animation: pinpulse 2.8s infinite;
}

.pin-us {
    left: 25.5%;
    top: 36%;
}

.pin-latam {
    left: 31%;
    top: 59%;
}

.pin-europe {
    left: 52.5%;
    top: 31%;
}

.pin-africa {
    left: 53%;
    top: 55%;
}

.pin-south-asia {
    left: 70.5%;
    top: 48%;
}

.pin-southeast-asia {
    left: 76%;
    top: 56%;
}

.map-credit {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-size: .62rem;
    line-height: 1.4;
    text-decoration: none;
}

.map-credit:hover {
    color: var(--accent);
}

@keyframes pinpulse {
    0% {
        transform: scale(.7);
        opacity: .75;
    }

    70%,
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .map-pin::after {
        animation: none;
        opacity: .4;
    }
}

.hero>* {
    position: relative;
    z-index: 1;
}

.hero {
    position: sticky;
    top: 74px;
    align-self: start;
    height: calc(100vh - 74px);
    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    border-left: 1px solid var(--line);
    position: relative;
    overflow: visible;
}

@media (max-width:880px) {
    .hero {
        position: static;
        height: auto;
        border-left: none;
        border-bottom: 1px solid var(--line);
        padding: 40px 26px;
        text-align: center;
        align-items: center;
    }
}

.hero .eyebrow {
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 16px;
}

.hero h1 {
    font-family: var(--display);
    font-weight: 500;
    font-size: clamp(2.8rem, 6vw, 4.2rem);
    line-height: .95;
    letter-spacing: -.03em;
    margin-bottom: 18px;
}

.hero-name {
    display: flex;
    align-items: flex-end;
    gap: 18px;
    margin-bottom: 18px;
}

.hero-name h1 {
    margin-bottom: 0;
}

.hero-pose-wrap {
    position: relative;
    width: 160px;
    height: 220px;
    flex: 0 0 auto;
    display: block;
    transform-origin: bottom center;
    animation: pose-float 4.8s ease-in-out infinite;
}

.hero-pose {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: bottom center;
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .2));
}

.speech-drift {
    position: absolute;
    top: 5%;
    left: 4%;
    width: 54%;
    height: 32%;
    pointer-events: none;
    animation: bubble-drift 3.8s ease-in-out infinite;
}

@keyframes pose-float {

    0%,
    100% {
        transform: translateY(0) rotate(-1deg);
    }

    50% {
        transform: translateY(-6px) rotate(1deg);
    }
}

@keyframes bubble-drift {

    0%,
    100% {
        transform: translate(0, 0) rotate(0);
    }

    50% {
        transform: translate(2px, -3px) rotate(1deg);
    }
}

@media (max-width:880px) {
    .hero-name {
        align-items: center;
        justify-content: center;
    }
}

@media (max-width:560px) {
    .hero-name {
        gap: 10px;
    }

    .hero-pose {
        width: 100%;
        height: 100%;
    }

    .hero-pose-wrap {
        width: 100px;
        height: 138px;
    }
}

@media (prefers-reduced-motion: reduce) {

    .hero-pose-wrap,
    .speech-drift {
        animation: none;
    }
}

.hero .sub {
    font-size: 1.12rem;
    color: var(--muted);
    max-width: 34ch;
    line-height: 1.5;
    margin-bottom: 24px;
}

.open-badge {
    display: inline-block;
    text-align: center;
    font-size: .78rem;
    font-weight: 500;
    color: var(--accent);
    background: var(--accent-soft);
    padding: 7px 14px;
    border-radius: 30px;
    width: max-content;
}

@media (max-width:880px) {
    .open-badge {
        margin: 0 auto;
    }
}

.open-badge .dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: .5em;
    vertical-align: middle;
    border-radius: 50%;
    background: var(--accent);
    animation: pulse 1.8s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: .35;
    }
}

.rail {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 50px 22px;
    border-right: 1px solid var(--line);
    position: sticky;
    top: 74px;
    align-self: start;
    height: calc(100vh - 74px);
}

@media (max-width:880px) {
    .rail {
        position: static;
        height: auto;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        border-right: none;
        border-bottom: 1px solid var(--line);
        padding: 18px 20px;
    }
}

.rail a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 30px;
    border: 1px solid var(--line);
    text-decoration: none;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 500;
    white-space: nowrap;
    transition: all .2s, transform .15s;
}

.rail a .rnum {
    font-size: .62rem;
    opacity: .7;
    font-variant-numeric: tabular-nums;
}

.rail a:hover {
    border-color: var(--accent);
    color: var(--ink);
    transform: translateX(3px);
}

@media (max-width:880px) {
    .rail a:hover {
        transform: translateY(-2px);
    }
}

.rail a.active {
    background: var(--ink);
    border-color: var(--ink);
    color: #fff;
    position: relative;
}

.rail a.active::after {
    content: "";
    position: absolute;
    right: 14px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #fff;
    animation: blip 1.4s infinite;
}

@keyframes blip {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.5);
        opacity: .5;
    }
}

.seen-hint {
    font-size: .7rem;
    color: var(--muted);
    margin-top: 14px;
    letter-spacing: .04em;
}

.seen-hint b {
    color: var(--accent);
}

@media (max-width:880px) {
    .seen-hint {
        width: 100%;
        text-align: center;
        margin-top: 6px;
    }
}

.panel-wrap {
    padding: 50px 44px;
    min-width: 0;
}

@media (max-width:880px) {
    .panel-wrap {
        padding: 34px 26px;
    }
}

.view {
    display: none;
}

.view.active {
    display: block;
    animation: rise .5s cubic-bezier(.2, .7, .2, 1);
}

@keyframes rise {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .view.active {
        animation: none;
    }

}

.cap {
    font-style: italic;
    font-family: var(--display);
    font-size: 1.05rem;
    color: var(--muted);
    margin-bottom: 22px;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity .5s, transform .5s;
}

.cap.show {
    opacity: 1;
    transform: none;
}

.eyebrow {
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 10px;
    display: inline-flex;
}

h2.title {
    font-family: var(--display);
    font-weight: 400;
    font-size: clamp(1.9rem, 4vw, 2.6rem);
    letter-spacing: -.02em;
    margin-bottom: 8px;
    line-height: 1.05;
}

h3 {
    font-size: .95rem;
    font-weight: 600;
    margin-bottom: 2px;
}

p.lead {
    font-size: 1.2rem;
    color: var(--muted);
    max-width: 48ch;
    line-height: 1.45;
    margin-bottom: 20px;
}

p {
    margin-bottom: 16px;
}

.muted {
    color: var(--muted);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    font-size: .82rem;
    margin: 22px 0;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 30px;
    border: 1px solid var(--line);
    color: var(--muted);
}

.pill.hot {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    font-weight: 500;
}

.skills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.skill {
    font-size: .76rem;
    padding: 5px 12px;
    border-radius: 20px;
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 500;
}

.entry {
    display: grid;
    grid-template-columns: 118px 1fr;
    gap: 22px;
    padding: 18px 0;
    border-top: 1px solid var(--line);
}

.entry:first-of-type {
    border-top: none;
}

.entry .year {
    font-size: .8rem;
    color: var(--accent);
    font-variant-numeric: tabular-nums;
    padding-top: 2px;
    font-weight: 500;
}

.entry .org {
    font-size: .85rem;
    color: var(--muted);
    margin-top: 2px;
}

.entry ul {
    margin: 8px 0 0;
    padding-left: 16px;
}

.entry li {
    font-size: .86rem;
    color: var(--muted);
    margin-bottom: 4px;
}

.group-label {
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 26px 0 6px;
}

.group-label:first-child {
    margin-top: 0;
}

.cards {
    position: relative;
    height: 510px;
    overflow: hidden;
    perspective: 1400px;
    isolation: isolate;
}

.rcard {
    position: absolute;
    top: 8px;
    left: 50%;
    width: min(68%, 430px);
    height: 395px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    transform-origin: 50% 120%;
    transition: transform .65s cubic-bezier(.22, 1, .36, 1), opacity .4s ease, filter .4s ease, box-shadow .3s, border-color .3s;
    will-change: transform, opacity;
}

.rcard.is-active {
    border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
    box-shadow: 0 26px 60px -26px rgba(16, 42, 67, .55);
}

.rcard,
.demo,
.databrief {
    box-shadow: 0 12px 30px rgba(16, 42, 67, .07);
}

.rcard:hover {
    box-shadow: 0 22px 55px -24px rgba(0, 0, 0, .6);
    border-color: var(--accent);
}

.rcard .viz {
    transition: transform .35s ease;
}

.rcard.is-active .viz {
    transform: scale(1.03);
}

.rcard h3 {
    transition: color .2s;
}

.rcard.is-active h3 {
    color: var(--accent);
}

@media (prefers-reduced-motion: reduce) {
    .rcard {
        transition: none;
    }

    .rcard.is-active .viz {
        transform: none;
    }

    .rcard .body {
        transition: none;
    }
}

.rcard .viz {
    height: 156px;
    flex: 0 0 156px;
    border-bottom: 1px solid var(--line);
    background-size: cover;
    background-position: center;
}

.rcard .body {
    padding: 18px 20px;
}

.rcard h3 {
    font-family: var(--display);
    font-weight: 500;
    font-size: 1.12rem;
    margin-bottom: 7px;
}

.rcard p {
    font-size: .86rem;
    color: var(--muted);
    margin: 0;
}

.rcard .tag {
    margin-bottom: 9px;
}

/* Image-led trial card: persistent title, details revealed on interaction. */
.rcard--image-reveal {
    height: 435px;
    background: #17170f;
}

.rcard--image-reveal .viz {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background-position: center 42%;
    background-size: cover;
    transform: none;
    transition: transform .45s cubic-bezier(.22, 1, .36, 1), filter .35s ease;
}

.rcard--icc .viz {
    background-position: center 58%;
}

.rcard--image-reveal.is-active .viz {
    transform: none;
}

.rcard--image-reveal::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(12, 16, 18, .7);
    opacity: 0;
    transition: opacity .3s ease;
}

.rcard--image-reveal .body {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    min-height: 100%;
    padding: 28px 26px 112px;
    color: #fff;
}

.rcard--image-reveal .tag,
.rcard--image-reveal p {
    position: relative;
    z-index: 1;
    color: #fff;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .25s ease, transform .35s cubic-bezier(.22, 1, .36, 1);
}

.rcard--image-reveal h3 {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    min-height: 92px;
    margin: 0;
    padding: 16px 22px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 4px;
    background: rgba(12, 16, 18, .88);
    color: #fff;
    backdrop-filter: blur(5px);
}

.rcard--image-reveal .card-category {
    font-family: var(--body);
    font-size: .64rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: #e8b730;
}

.rcard--image-reveal.is-active h3 {
    color: #fff;
}

.rcard--image-reveal:hover::after,
.rcard--image-reveal:focus-visible::after {
    opacity: 1;
}

.rcard--image-reveal:hover .viz,
.rcard--image-reveal:focus-visible .viz {
    transform: scale(1.035);
    filter: saturate(.85);
}

.rcard--image-reveal:hover .tag,
.rcard--image-reveal:hover p,
.rcard--image-reveal:focus-visible .tag,
.rcard--image-reveal:focus-visible p {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .rcard--image-reveal .viz,
    .rcard--image-reveal::after,
    .rcard--image-reveal .tag,
    .rcard--image-reveal p {
        transition: none;
    }

    .rcard--image-reveal:hover .viz,
    .rcard--image-reveal:focus-visible .viz {
        transform: none;
    }
}

.cards::after {
    content: 'Select a card or use the arrow buttons';
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--muted);
    font-size: .72rem;
    white-space: nowrap;
}

.project-carousel-btn {
    position: absolute;
    bottom: 30px;
    z-index: 10;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: var(--card);
    color: var(--accent);
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(16, 42, 67, .12);
    transition: transform .2s ease, border-color .2s ease;
}

.project-carousel-btn:hover,
.project-carousel-btn:focus-visible {
    transform: translateY(-2px);
    border-color: var(--accent);
}

.project-carousel-prev {
    left: calc(50% - 52px);
}

.project-carousel-next {
    right: calc(50% - 52px);
}

@media (max-width:760px) {
    .cards {
        display: grid;
        grid-template-columns: 1fr;
        gap: 16px;
        height: auto;
        overflow: visible;
        perspective: none;
    }

    .rcard {
        position: relative;
        inset: auto;
        width: auto;
        height: auto;
        display: block;
        opacity: 1 !important;
        filter: none !important;
        transform: none !important;
    }

    .rcard--image-reveal {
        height: 435px;
    }

    .rcard--image-reveal::after {
        opacity: .64;
    }

    .rcard--image-reveal .tag,
    .rcard--image-reveal p {
        opacity: 1;
        transform: none;
    }

    .cards::after,
    .project-carousel-btn {
        display: none;
    }
}

.tag {
    display: inline-block;
    font-size: .64rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent);
    background: var(--accent-soft);
    padding: 4px 10px;
    border-radius: 20px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--accent);
    color: #fff;
    text-decoration: none;
    font-size: .92rem;
    font-weight: 600;
    padding: 14px 26px;
    border-radius: 30px;
    transition: transform .2s, opacity .2s;
    margin-top: 8px;
}

.btn,
.btn-sm,
.pill.hot {
    background: var(--accent2);
    border-color: var(--accent2);
}

.btn:hover {
    transform: translateY(-2px);
    opacity: .92;
}

.contact {
    border-top: 1px solid var(--line);
    margin-top: 50px;
    padding-top: 36px;
}

.contact h3 {
    font-family: var(--display);
    font-weight: 500;
    font-size: 1.5rem;
    margin-bottom: 6px;
}

.contact p {
    color: var(--muted);
    margin-bottom: 18px;
}

.contact .links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.sec-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.sec-pose {
    height: 104px;
    flex: 0 0 auto;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, .3));
    transition: transform .3s cubic-bezier(.34, 1.56, .64, 1);
}

.sec-pose:hover {
    transform: translateY(-4px) rotate(-2deg) scale(1.04);
}

@media (max-width:600px) {
    .sec-pose {
        height: 64px;
    }
}

#ambient {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: .45;
}

.wm-land {
    fill: var(--ink);
    opacity: .16;
}

.tracking {
    margin-left:30px;
    margin-top: 16px;
    font-size: .74rem;
    color: var(--muted);
    line-height: 1.6;
    max-width: 40ch;
}

.tracking b {
    color: var(--accent);
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    font-size: .68rem;
    margin-right: 6px;
}

@media (max-width:880px) {
    .tracking {
        margin-left: auto;
        margin-right: auto;
    }
}

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin: 26px 0 6px;
}

@media (max-width:640px) {
    .stats {
        grid-template-columns: 1fr 1fr;
    }
}

.stat .num {
    display: block;
    font-family: var(--display);
    font-size: 2rem;
    font-weight: 500;
    color: var(--accent);
    line-height: 1;
}

.stat .lbl {
    font-size: .74rem;
    color: var(--muted);
    line-height: 1.4;
    display: block;
    margin-top: 4px;
}

.pullq {
    font-family: var(--display);
    font-style: italic;
    font-size: 1.45rem;
    line-height: 1.35;
    color: var(--ink);
    border-left: 3px solid var(--accent);
    padding: 6px 0 6px 20px;
    margin: 26px 0;
    max-width: 46ch;
}

.regline {
    margin: 30px 0 8px;
}

.regtrack {
    position: relative;
    height: 2px;
    background: var(--line);
    margin: 30px 8px 0;
}

.regitems {
    display: flex;
    justify-content: space-between;
    margin: 0 0 6px;
}

.regit {
    position: relative;
    text-align: center;
    flex: 1;
}

.regit .rdot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--accent);
    margin: 0 auto;
    position: relative;
    top: -3.5px;
    border: 2px solid var(--bg);
}

.regit .rname {
    font-size: .72rem;
    font-weight: 600;
    color: var(--ink);
    margin-top: 8px;
}

.regit .ryear {
    font-size: .68rem;
    color: var(--muted);
}

.regit.fut .rdot {
    background: var(--bg);
    border: 2px solid var(--accent);
    top: -4.5px;
}

.demo {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 24px 26px;
    margin: 6px 0 30px;
}

.demo .dtxt {
    font-size: .98rem;
    line-height: 1.6;
    min-height: 84px;
    margin-bottom: 6px;
    transition: opacity .25s;
}

.demo .dtxt.dense {
    color: var(--muted);
    font-style: normal;
}

.demo .dtxt.plain {
    color: var(--ink);
}

.demo .dsrc {
    font-size: .72rem;
    color: var(--muted);
    margin-bottom: 14px;
}

.btn-sm {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    color: #fff;
    border: none;
    font-family: var(--body);
    font-size: .82rem;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 24px;
    transition: transform .2s, opacity .2s;
}

.btn-sm:hover {
    transform: translateY(-2px);
    opacity: .92;
}

.databrief {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 26px 28px;
    margin: 30px 0;
}

.databrief .dbtag {
    display: inline-block;
    font-size: .64rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent);
    background: var(--accent-soft);
    padding: 4px 10px;
    border-radius: 20px;
    margin-bottom: 12px;
}

.databrief h3 {
    font-family: var(--display);
    font-weight: 500;
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.databrief .dbsub {
    font-size: .86rem;
    color: var(--muted);
    margin-bottom: 20px;
}

.dbchart {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    height: 170px;
    padding: 0 4px 0;
    border-bottom: 1px solid var(--line);
    margin-bottom: 8px;
}

.dbbar {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    height: 100%;
}

.dbbar .bar {
    width: 100%;
    max-width: 54px;
    border-radius: 6px 6px 0 0;
    background: linear-gradient(var(--accent2), var(--accent));
    height: 0;
    transition: height 1s cubic-bezier(.2, .7, .2, 1);
    position: relative;
}

.dbbar .bar.lo {
    background: linear-gradient(var(--accent2), var(--accent));
}

.dbbar .bv {
    font-size: .74rem;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 6px;
    opacity: 0;
    transition: opacity .5s .4s;
}

.dbbar.shown .bv {
    opacity: 1;
}

.dblabels {
    display: flex;
    gap: 10px;
    padding: 8px 4px 0;
}

.dblabels span {
    flex: 1;
    text-align: center;
    font-size: .7rem;
    color: var(--muted);
}

.databrief .dbnote {
    font-size: .92rem;
    line-height: 1.6;
    color: var(--ink);
    margin-top: 18px;
}

.databrief .dbnote b {
    color: var(--accent);
}

.databrief .dbsrc {
    font-size: .72rem;
    color: var(--muted);
    margin-top: 12px;
}

/* PDF Viewer Modal */
.pdf-modal {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: none;
    align-items: center;
    justify-content: center;
}

.pdf-modal.open {
    display: flex;
}

.pdf-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .82);
    backdrop-filter: blur(8px);
}

.pdf-viewer {
    position: relative;
    width: 90vw;
    height: 90vh;
    max-width: 1100px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .6);
    animation: pdfIn .35s cubic-bezier(.2, .7, .2, 1);
}

@keyframes pdfIn {
    from {
        opacity: 0;
        transform: scale(.94) translateY(20px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.pdf-close {
    position: absolute;
    top: 12px;
    right: 16px;
    z-index: 10;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--card);
    color: var(--ink);
    font-size: 1.4rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .2s, background .2s;
}

.pdf-close:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent);
}

.pdf-controls {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 30px;
    padding: 8px 20px;
}

.pdf-prev,
.pdf-next {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid var(--line);
    background: var(--bg);
    color: var(--ink);
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .2s, background .2s;
}

.pdf-prev:hover,
.pdf-next:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent);
}

.pdf-prev:disabled,
.pdf-next:disabled {
    opacity: .35;
    pointer-events: none;
}

.pdf-pageinfo {
    font-size: .82rem;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
    min-width: 80px;
    text-align: center;
}

.pdf-canvas-wrap {
    position: absolute;
    inset: 0;
    overflow: auto;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 20px;
}

.pdf-canvas-wrap canvas {
    display: block;
    max-width: 100%;
    height: auto;
    box-shadow: 0 4px 24px rgba(0, 0, 0, .4);
}

@media (max-width: 768px) {
    .pdf-viewer {
        width: 96vw;
        height: 92vh;
    }

    .pdf-canvas-wrap {
        padding: 12px;
    }
}

/* =============================================
   ENHANCEMENT 1: Cursor light orb
   ============================================= */
.light-orb {
    position: fixed;
    top: 0;
    left: 0;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(8, 127, 140, .08) 0%, rgba(8, 127, 140, .03) 35%, transparent 70%);
    will-change: left, top;
}

@media (max-width: 880px) {
    .light-orb {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .light-orb {
        display: none;
    }
}

/* =============================================
   ENHANCEMENT 3: Scroll-triggered staggered reveals
   ============================================= */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity .6s cubic-bezier(.2, .7, .2, 1), transform .6s cubic-bezier(.2, .7, .2, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: .05s; }
.reveal-delay-2 { transition-delay: .1s; }
.reveal-delay-3 { transition-delay: .15s; }
.reveal-delay-4 { transition-delay: .2s; }
.reveal-delay-5 { transition-delay: .25s; }
.reveal-delay-6 { transition-delay: .3s; }
.reveal-delay-7 { transition-delay: .35s; }
.reveal-delay-8 { transition-delay: .4s; }

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* =============================================
   ENHANCEMENT 4: 3D tilt on hero panel
   ============================================= */
.hero {
    perspective: 800px;
    transition: transform .15s ease-out;
}

.hero>* {
    transform-style: preserve-3d;
}

@media (max-width: 880px) {
    .hero {
        perspective: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero {
        perspective: none;
        transition: none;
    }
}

/* =============================================
   ENHANCEMENT 6: Map pins sequence spotlight
   ============================================= */
@keyframes pinspotlight {
    0% {
        box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent2) 24%, transparent);
        transform: translate(-50%, -50%) scale(1);
    }
    30% {
        box-shadow: 0 0 0 18px color-mix(in srgb, var(--accent2) 60%, transparent), 0 0 30px var(--accent2);
        transform: translate(-50%, -50%) scale(1.8);
    }
    100% {
        box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent2) 24%, transparent);
        transform: translate(-50%, -50%) scale(1);
    }
}

.map-pin.spotlight {
    animation: pinspotlight .7s ease-out;
}

.map-pin.spotlight::after {
    animation: pinpulse .6s infinite;
}

/* =============================================
   ENHANCEMENT 7: Skill tag & pill hover glow
   ============================================= */
.skill {
    transition: background .25s, color .25s, box-shadow .25s, transform .2s;
}

.skill:hover {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 0 16px color-mix(in srgb, var(--accent) 40%, transparent);
    transform: translateY(-2px);
}

.pill {
    transition: border-color .25s, color .25s, box-shadow .25s, transform .2s, background .25s;
}

.pill:hover {
    border-color: var(--accent);
    color: var(--accent);
    box-shadow: 0 0 14px color-mix(in srgb, var(--accent) 25%, transparent);
    transform: translateY(-2px);
}

.tag {
    transition: background .25s, color .25s, box-shadow .25s, transform .2s;
}

.tag:hover {
    box-shadow: 0 0 12px color-mix(in srgb, var(--accent) 30%, transparent);
    transform: translateY(-1px);
}

.stat {
    transition: transform .25s;
}

.stat:hover {
    transform: translateY(-3px);
}

.stat .num {
    transition: color .25s, text-shadow .25s;
}

.stat:hover .num {
    text-shadow: 0 0 18px color-mix(in srgb, var(--accent) 35%, transparent);
}

/* =============================================
   LANDING OVERLAY
   ============================================= */
.landing-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transition: opacity .5s cubic-bezier(.2, .7, .2, 1), visibility .5s;
}

/* Cinema-roll keyframe — continuous horizontal scroll */
@keyframes bandScrollRight {
    0%   { background-position: 0 0; }
    100% { background-position: -200% 0; }
}

@keyframes bandScrollLeft {
    0%   { background-position: 0 0; }
    100% { background-position: 200% 0; }
}

/* Top band with portfolio image — scrolls right */
.landing-overlay::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 120px;
    z-index: 2;
    background-image: url('../documents/portfolio image.png');
    background-size: auto 100%;
    background-repeat: repeat-x;
    animation: bandScrollRight 30s linear infinite;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    pointer-events: none;
}

/* Bottom band with portfolio image — scrolls left (opposite direction) */
.landing-overlay::after {
    content: '';
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    z-index: 2;
    background-image: url('../documents/portfolio image.png');
    background-size: auto 100%;
    background-repeat: repeat-x;
    animation: bandScrollLeft 30s linear infinite;
    mask-image: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0) 100%);
    pointer-events: none;
}

.landing-overlay.dismissed {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.landing-bg {
    position: absolute;
    inset: 0;
    background-color: var(--bg);
    background-image:
        radial-gradient(circle at 12% 8%, rgba(255, 255, 255, .72), transparent 30%),
        radial-gradient(circle at 88% 82%, rgba(239, 125, 98, .1), transparent 26%);
    background-size: auto, auto;
    background-attachment: fixed;
    animation: bg-breathe 24s ease-in-out infinite alternate;
}

/* Cursor-reactive grid, adapted from React Bits for this vanilla JS site. */
.cursor-grid {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
    pointer-events: none;
}

.cursor-grid__canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.landing-content {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: 40px 24px 40px;
    max-width: 700px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Avatar */
.landing-avatar-wrap {
    width: 180px;
    height: 240px;
    margin-bottom: 28px;
    animation: landing-float 4.8s ease-in-out infinite;
    filter: drop-shadow(0 14px 28px rgba(0, 0, 0, .25));
}

.landing-avatar {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: bottom center;
}

@keyframes landing-float {
    0%, 100% { transform: translateY(0) rotate(-1deg); }
    50% { transform: translateY(-8px) rotate(1deg); }
}

/* Headline */
.landing-headline {
    font-family: var(--body);
    font-weight: 400;
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    color: var(--ink);
    line-height: 1.25;
    margin-bottom: 10px;
    letter-spacing: -.01em;
}

/* Name span — inline with headline */
.landing-name {
    font-family: var(--display);
    font-weight: 500;
    font-style: italic;
    color: var(--accent);
}

/* Pen cursor — inline after the name, positioned by JS */
.landing-pen {
    display: inline-block;
    font-size: 1.3rem;
    color: var(--accent);
    vertical-align: baseline;
    margin-left: 4px;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .2));
    transform: rotate(-30deg);
    transition: opacity .4s ease;
}

.landing-pen.done {
    opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
    .landing-pen {
        display: none;
    }
}

.landing-sub {
    font-family: var(--display);
    font-size: clamp(1.05rem, 2.5vw, 1.35rem);
    color: var(--muted);
    font-style: italic;
    margin-bottom: 14px;
    line-height: 1.35;
}

.landing-tagline {
    font-family: var(--body);
    font-size: .92rem;
    color: var(--muted);
    max-width: 44ch;
    line-height: 1.55;
    margin-bottom: 40px;
    text-align: center;
    text-align-last: auto;
    text-justify: auto;
    text-wrap: wrap;
    hyphens: none;
    overflow-wrap: normal;
}

/* Section cards */
.landing-cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 32px;
}

.landing-card {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 22px;
    border-radius: 30px;
    border: 1px solid var(--line);
    background: var(--card);
    color: var(--muted);
    font-family: var(--body);
    font-size: .88rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all .25s cubic-bezier(.2, .7, .2, 1), transform .2s;
    opacity: 0;
    transform: translateY(20px);
}

.landing-card.revealed {
    opacity: 1;
    transform: translateY(0);
    transition: opacity .5s cubic-bezier(.2, .7, .2, 1), transform .5s cubic-bezier(.2, .7, .2, 1), border-color .25s, color .25s, box-shadow .25s, background .25s;
}

.landing-card:hover {
    border-color: var(--accent);
    color: var(--ink);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(8, 127, 140, .14);
}

.landing-card-num {
    font-size: .64rem;
    font-weight: 600;
    letter-spacing: .08em;
    color: var(--accent);
    opacity: .8;
}

.landing-card-label {
    font-weight: 500;
}

/* Skip link */
.landing-skip {
    font-family: var(--body);
    font-size: .92rem;
    font-weight: 700;
    color: var(--accent);
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 20px;
    transition: background .2s, opacity .2s;
    opacity: 0;
    animation: landing-fade-in .6s 2.6s forwards;
}

.landing-skip:hover {
    background: var(--accent-soft);
    opacity: 1;
}

@keyframes landing-fade-in {
    to { opacity: 1; }
}

/* Responsive */
@media (max-width: 560px) {
    .landing-avatar-wrap {
        width: 130px;
        height: 175px;
        margin-bottom: 20px;
    }

    .landing-cards {
        gap: 8px;
    }

    .landing-card {
        padding: 10px 16px;
        font-size: .8rem;
    }

    .landing-content {
        padding: 30px 16px 50px;
    }

    .landing-tagline {
        margin-bottom: 28px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .landing-avatar-wrap {
        animation: none;
    }

    .landing-card {
        opacity: 1;
        transform: none;
        transition: border-color .25s, color .25s, box-shadow .25s, background .25s;
    }

    .landing-card.revealed {
        transition: border-color .25s, color .25s, box-shadow .25s, background .25s;
    }

    .landing-skip {
        opacity: 1;
        animation: none;
    }
}
