:root {
    --navy: #0a192f;
    --navy-light: #112240;
    --navy-lighter: #172f51;
    --teal: #64ffda;
    --text: #ccd6f6;
    --muted: #a8b2d1;
    --subtle: #8892b0;
    --border: rgba(100, 255, 218, 0.22);
    --shadow: 0 18px 45px rgba(2, 12, 27, 0.28);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--navy);
    color: var(--text);
    font-family: Arial, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

body.modal-open {
    overflow: hidden;
}

a,
button {
    font: inherit;
}

a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--teal);
    outline-offset: 4px;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    width: 100%;
    min-height: 70px;
    padding: 1rem 2rem;
    background: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(8px);
    box-shadow: 0 8px 24px rgba(2, 12, 27, 0.2);
}

.navbar-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.navbar a {
    color: var(--teal);
    text-decoration: none;
}

.navbar a:hover {
    text-decoration: underline;
}

.resume-button {
    padding: 0.35rem 1rem;
    border: 2px solid var(--teal);
    border-radius: 5px;
    transition: background 0.25s ease, color 0.25s ease;
}

.resume-button:hover {
    background: var(--teal);
    color: var(--navy);
    text-decoration: none !important;
}

.menu-toggle {
    display: none;
    padding: 0.2rem 0.5rem;
    border: 0;
    background: transparent;
    color: var(--teal);
    cursor: pointer;
    font-size: 2rem;
}

.container {
    width: min(1120px, 84%);
    margin: 0 auto;
}

.hero {
    min-height: 82vh;
    display: flex;
    align-items: center;
    padding: 9rem 0 5rem;
    background:
        radial-gradient(circle at 83% 22%, rgba(100, 255, 218, 0.10), transparent 24rem),
        var(--navy);
}

.eyebrow {
    margin-bottom: 0.8rem;
    color: var(--teal);
    font-size: 1rem;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

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

h1 {
    max-width: 900px;
    margin-bottom: 1.25rem;
    font-size: clamp(3rem, 7vw, 5.6rem);
    line-height: 1.04;
    letter-spacing: -0.04em;
}

h2 {
    margin-bottom: 1rem;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.15;
}

h3 {
    line-height: 1.3;
}

.hero-copy {
    max-width: 800px;
    margin-bottom: 2rem;
    color: var(--muted);
    font-size: clamp(1.05rem, 2vw, 1.35rem);
}

.hero-link {
    display: inline-block;
    padding: 0.75rem 1.4rem;
    border: 2px solid var(--teal);
    border-radius: 5px;
    color: var(--teal);
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease;
}

.hero-link:hover {
    background: var(--teal);
    color: var(--navy);
}

.section {
    padding: 6rem 0;
}

.section-alt {
    background: var(--navy-light);
}

.section-intro {
    max-width: 750px;
    margin-bottom: 2.5rem;
    color: var(--subtle);
    font-size: 1.05rem;
}

.stats {
    padding: 0 0 6rem;
}

.stats-panel {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--navy-light);
    box-shadow: var(--shadow);
}

.stat {
    padding: 2.2rem;
    text-align: center;
}

.stat + .stat {
    border-left: 1px solid var(--border);
}

.stat-number {
    display: block;
    color: var(--teal);
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    font-weight: 700;
    line-height: 1;
}

.stat-label {
    display: block;
    margin-top: 0.7rem;
    color: var(--muted);
    font-size: 1.05rem;
}

.showcase-group + .showcase-group {
    margin-top: 4rem;
}

.group-heading {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.3rem;
    color: var(--muted);
    font-size: 1.25rem;
}

.group-heading::after {
    content: "";
    width: min(240px, 35vw);
    height: 1px;
    background: var(--border);
}

.showcase-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
}

.showcase-card {
    min-height: 255px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.6rem;
    border: 1px solid transparent;
    border-radius: 10px;
    background: var(--navy-light);
    color: var(--text);
    cursor: pointer;
    text-align: left;
    box-shadow: 0 12px 28px rgba(2, 12, 27, 0.2);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.showcase-card--image {
    min-height: 0;
    align-items: stretch;
    overflow: hidden;
    padding: 0;
    text-decoration: none;
}

.showcase-card--image:not(a):not(button) {
    cursor: default;
}

.showcase-image-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    flex: 0 0 auto;
    border-bottom: 1px solid rgba(136, 146, 176, 0.16);
    background: var(--navy-lighter);
}

.showcase-image {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    border-radius: 0;
    object-fit: cover;
    object-position: center;
    box-shadow: none;
}

.showcase-image--contain {
    object-fit: contain;
    padding: 0.45rem;
}

.showcase-image-placeholder {
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 28% 25%, rgba(100, 255, 218, 0.13), transparent 32%),
        var(--navy-lighter);
    color: var(--subtle);
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.showcase-card-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.4rem 1.6rem 1.6rem;
}
.showcase-card > .showcase-image-frame {
    margin-bottom: 1.5rem;
}

.showcase-card--image .card-number {
    margin-bottom: 0.75rem;
}

.showcase-card--image .card-link {
    margin-top: auto;
}

.section-alt .showcase-card {
    background: var(--navy);
}

.showcase-card:hover {
    transform: translateY(-5px);
    border-color: var(--border);
    box-shadow: 0 18px 34px rgba(2, 12, 27, 0.34);
}

.card-number {
    margin-bottom: 1.7rem;
    color: var(--teal);
    font-size: 0.85rem;
    letter-spacing: 0.1em;
}

.showcase-card h3 {
    margin-bottom: 0.7rem;
    font-size: 1.25rem;
}

.showcase-card p {
    margin-bottom: 1.3rem;
    color: var(--subtle);
}

.card-link {
    margin-top: auto;
    color: var(--teal);
    font-size: 0.95rem;
}

.card-link {
    display: inline-block;
    padding: 0.10rem 1rem;
    border: 2px solid var(--teal);
    border-radius: 15px;
    color: var(--teal);
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease;
}

.card-link:hover {
    background: var(--teal);
    color: var(--navy);
}

.areas-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1rem;
}

.area-card {
    appearance: none;
    position: relative;
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 175px;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--text);
    cursor: pointer;
    perspective: 1000px;
    text-align: center;
}

.area-card-inner {
    position: relative;
    display: block;
    width: 100%;
    height: 175px;
    transform-style: preserve-3d;
    transition: transform 0.45s ease;
}

.area-card.is-flipped .area-card-inner {
    transform: rotateY(180deg);
}

.area-card-front,
.area-card-back {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 1.25rem 0.8rem;
    overflow: hidden;
    border: 1px solid rgba(136, 146, 176, 0.18);
    border-radius: 10px;
    background: var(--navy-light);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.area-card-back {
    transform: rotateY(180deg);
}
.area-card:hover .area-card-inner,
.area-card:focus-within .area-card-inner {
    transform: rotateY(180deg);
}
.area-card:hover .area-card-front,
.area-card:hover .area-card-back,
.area-card:focus-visible .area-card-front,
.area-card:focus-visible .area-card-back {
    border-color: var(--border);
    box-shadow: 0 16px 30px rgba(2, 12, 27, 0.3);
}

.area-icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-bottom: 0.85rem;
    color: var(--teal);
    font-size: 2.75rem;
}

.area-title {
    display: block;
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.3;
}

.area-subheading {
    display: block;
    margin-top: 0.4rem;
    color: var(--teal);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.area-highlights {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-top: 0.7rem;
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.3;
}

.area-highlights > span::before {
    content: "•";
    margin-right: 0.35rem;
    color: var(--teal);
}

.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.25rem;
}

.capability-column {
    padding: 1.6rem;
    border-top: 3px solid var(--teal);
    border-radius: 8px;
    background: var(--navy);
    box-shadow: 0 12px 28px rgba(2, 12, 27, 0.2);
}

.capability-column h3 {
    min-height: 3.3rem;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.capability-column ul {
    margin: 0;
    padding-left: 1.15rem;
    color: var(--subtle);
}

.capability-column li {
    margin-bottom: 0.55rem;
}

.capability-column li::marker {
    color: var(--teal);
}

.confidentiality-note {
    max-width: 870px;
    margin: 4rem auto 0;
    padding: 1.4rem 1.6rem;
    border-left: 3px solid var(--teal);
    background: rgba(100, 255, 218, 0.055);
    color: var(--muted);
}

dialog {
    width: min(680px, calc(100% - 2rem));
    max-height: calc(100vh - 3rem);
    padding: 0;
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--navy-light);
    color: var(--text);
    box-shadow: 0 25px 75px rgba(2, 12, 27, 0.75);
}

dialog::backdrop {
    background: rgba(2, 12, 27, 0.82);
    backdrop-filter: blur(4px);
}

.dialog-content {
    position: relative;
    padding: 2.3rem;
}

.dialog-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: transparent;
    color: var(--teal);
    cursor: pointer;
    font-size: 1.4rem;
}

.dialog-label {
    margin-bottom: 0.6rem;
    color: var(--teal);
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.dialog-content h2 {
    max-width: calc(100% - 3rem);
    font-size: 1.8rem;
}

.dialog-content h3 {
    margin: 1.5rem 0 0.4rem;
    color: var(--muted);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.dialog-content p {
    color: var(--subtle);
}

.format-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-top: 1rem;
}

.format-tag {
    padding: 0.25rem 0.65rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--teal);
    font-size: 0.82rem;
}

.fade-in {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.fade-in.in-view {
    opacity: 1;
    transform: translateY(0);
}

#backToTop {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 900;
    padding: 0.5rem 0.8rem;
    border-radius: 5px;
    background: var(--teal);
    color: var(--navy);
    font-weight: 700;
    text-decoration: none;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

#backToTop.visible {
    opacity: 1;
    pointer-events: auto;
}

footer {
    padding: 2rem 1rem;
    background: var(--navy);
    color: var(--subtle);
    text-align: center;
}

@media (max-width: 980px) {
    .areas-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .capabilities-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .navbar {
        min-height: 64px;
        padding: 0.65rem 1rem;
    }

    .menu-toggle {
        display: block;
    }

    .navbar-links {
        position: absolute;
        top: 64px;
        right: 0;
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 0;
        padding: 1rem;
        background: var(--navy);
        box-shadow: 0 12px 24px rgba(2, 12, 27, 0.35);
    }

    .navbar-links.active {
        display: flex;
    }

    .navbar-links a {
        width: 100%;
        padding: 0.75rem;
        text-align: center;
    }

    .container {
        width: min(90%, 680px);
    }

    .hero {
        min-height: auto;
        padding-top: 9rem;
    }

    .showcase-grid {
        grid-template-columns: 1fr;
    }

    .showcase-card {
        min-height: 220px;
    }
}

@media (max-width: 560px) {
    .section {
        padding: 4.5rem 0;
    }

    .stats-panel,
    .areas-grid,
    .capabilities-grid {
        grid-template-columns: 1fr;
    }

    .stat + .stat {
        border-top: 1px solid var(--border);
        border-left: 0;
    }

    .area-card {
        min-height: 165px;
    }

    .area-card-inner {
        height: 165px;
    }

    .capability-column h3 {
        min-height: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

    .fade-in {
        opacity: 1;
        transform: none;
    }
}

/* Homepage */
.hero-actions,
.contact-actions,
.inline-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem;
}

.text-link,
.inline-links a,
.project-link {
    color: var(--teal);
    text-decoration: none;
}

.text-link:hover,
.inline-links a:hover,
.project-link:hover {
    text-decoration: underline;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    align-items: center;
    gap: clamp(2rem, 6vw, 5rem);
    margin-top: 2.25rem;
}

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

.profile-copy p {
    margin-bottom: 1rem;
}

.inline-links {
    margin-top: 1.6rem;
}

.headshot,
.profile-grid > img {
    display: block;
    width: min(280px, 70vw);
    height: min(280px, 70vw);
    margin: 0 auto;
    object-fit: cover;
    object-position: center;
    border: 2px solid var(--border);
    border-radius: 50%;
    box-shadow: var(--shadow);
    justify-self: center;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.35rem;
}

.project-card {
    overflow: hidden;
    border: 1px solid rgba(136, 146, 176, 0.16);
    border-radius: 10px;
    background: var(--navy-light);
    box-shadow: 0 12px 28px rgba(2, 12, 27, 0.2);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--border);
    box-shadow: 0 18px 34px rgba(2, 12, 27, 0.34);
}

.project-image,
.project-art {
    width: 100%;
    height: 250px;
}

.project-image {
    display: block;
    object-fit: cover;
    border-bottom: 1px solid rgba(136, 146, 176, 0.14);
}

.project-art {
    display: grid;
    place-items: center;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background:
        radial-gradient(circle at 25% 25%, rgba(100, 255, 218, 0.18), transparent 28%),
        linear-gradient(135deg, var(--navy-lighter), var(--navy));
}

.project-art span {
    display: grid;
    place-items: center;
    width: 112px;
    height: 112px;
    border: 1px solid var(--teal);
    border-radius: 50%;
    color: var(--teal);
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.project-card-content {
    padding: 1.6rem;
}

.project-card-content h3 {
    margin-bottom: 0.7rem;
    font-size: 1.35rem;
}

.project-card-content > p:not(.project-type) {
    min-height: 4.8rem;
    margin-bottom: 1.4rem;
    color: var(--subtle);
}

.project-type {
    margin-bottom: 0.55rem;
    color: var(--teal);
    font-size: 0.78rem;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.interests-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.75fr) minmax(420px, 1.25fr);
    align-items: start;
    gap: clamp(2rem, 5vw, 4rem);
    margin-top: 2.25rem;
}

.interests-copy {
    color: var(--muted);
    font-size: 1.05rem;
}

.carousel {
    padding: 1rem;
    border: 1px solid rgba(136, 146, 176, 0.16);
    border-radius: 10px;
    background: var(--navy);
    box-shadow: var(--shadow);
}

.image-rotator {
    position: relative;
    height: 390px;
    overflow: hidden;
    border-radius: 7px;
    background: var(--navy-lighter);
}

.image-rotator img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.image-rotator img.active {
    opacity: 1;
}

.image-rotator video {
    display: block;
    width: 100%;
    height: 100%;
    margin: 0;
    border-radius: 0;
    object-fit: contain;
    object-position: center;
    box-shadow: none;
}
.image-description {
    min-height: 1.6rem;
    margin: 0.9rem 0 0;
    color: var(--muted);
    text-align: center;
}

.image-controls {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 0.8rem;
}

.image-controls button {
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--teal);
    border-radius: 5px;
    background: transparent;
    color: var(--teal);
    cursor: pointer;
    transition: background 0.25s ease, color 0.25s ease;
}

.image-controls button:hover {
    background: var(--teal);
    color: var(--navy);
}

.contact-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 3rem;
    padding: clamp(2rem, 5vw, 3.5rem);
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--navy-light);
    box-shadow: var(--shadow);
}

.contact-panel h2 {
    margin-bottom: 0.5rem;
}

.contact-panel p:last-child {
    max-width: 650px;
    margin-bottom: 0;
    color: var(--muted);
}

.contact-actions {
    min-width: max-content;
    flex-direction: column;
}

.profile-copy a {
    display: inline-block;
    background: transparent;
    color: #64ffda;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s, color 0.3s;
}

.profile-copy a:hover {
    background: #64ffda;
    color: #0a192f;
}



@media (max-width: 820px) {
    .profile-grid,
    .interests-layout {
        grid-template-columns: 1fr;
    }

    .headshot,
    .profile-grid > img {
        grid-row: 1;
    }

    .interests-layout {
        gap: 2rem;
    }

    .contact-panel {
        align-items: flex-start;
        flex-direction: column;
    }

    .contact-actions {
        align-items: flex-start;
    }
}

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

    .project-card-content > p:not(.project-type) {
        min-height: auto;
    }

    .image-rotator {
        height: 300px;
    }

    .hero-actions {
        align-items: flex-start;
        flex-direction: column;
    }
}
