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

html { scroll-behavior: smooth; }

body {
    font-family: Arial, Helvetica, sans-serif;
    background: #f7f7f5;
    color: #202020;
    line-height: 1.6;
}

a { color: inherit; }

nav {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 7%;
    background: rgba(255,255,255,.97);
    border-bottom: 1px solid #e5e5e5;
}

.nav-name {
    font-size: 19px;
    font-weight: 700;
    letter-spacing: .5px;
    text-decoration: none;
}

.nav-links a {
    text-decoration: none;
    margin-left: 28px;
    font-size: 14px;
    font-weight: 600;
}

.nav-links a:hover { color: #500000; }

.hero {
    min-height: 82vh;
    display: flex;
    align-items: center;
    padding: 80px 10%;
    background: #17191c;
    color: white;
}

.hero-content { max-width: 900px; }

.eyebrow, .section-label {
    color: #500000;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.hero .eyebrow, .dark .section-label, .project-detail-hero .eyebrow {
    color: #d5b9bf;
}

.hero h1 {
    font-size: 68px;
    line-height: 1;
    margin-bottom: 20px;
}

.hero h2 {
    font-size: 27px;
    font-weight: 400;
    color: #d8d8d8;
    margin-bottom: 25px;
}

.hero p {
    max-width: 720px;
    color: #c5c5c5;
    font-size: 18px;
    margin-bottom: 35px;
}

.button {
    display: inline-block;
    padding: 12px 20px;
    margin-right: 10px;
    margin-bottom: 10px;
    background: #500000;
    color: white;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    transition: .2s;
}

.button:hover { transform: translateY(-2px); }
.button-outline { background: transparent; border: 1px solid #888; }

section { padding: 85px 10%; }

section h2 {
    font-size: 39px;
    line-height: 1.15;
    margin-bottom: 20px;
}

.section-intro {
    max-width: 760px;
    color: #666;
    font-size: 17px;
    margin-bottom: 45px;
}

.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
    gap: 56px;
    align-items: center;
}

.about-text p {
    margin-bottom: 18px;
    font-size: 17px;
    color: #505050;
}

.about-photo {
    width: 100%;
    max-width: 520px;
    margin-left: auto;
    border-radius: 8px;
    background: transparent;
    display: block;
    padding: 0;
    color: #777;
    overflow: hidden;
}

.about-photo img {
    width: 100%;
    height: auto;
    min-height: 0;
    display: block;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,.08);
}

.projects { background: #ececea; }

.project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.project-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
    height: 100%;
}

.project-card {
    background: white;
    border-radius: 9px;
    overflow: hidden;
    border: 1px solid #ddddda;
    transition: .2s;
    height: 100%;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,.08);
}

.project-media {
    height: 230px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #d6d6d1;
    color: #737373;
    text-align: center;
    overflow: hidden;
}

.project-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.project-content { padding: 25px; }
.project-content h3 { font-size: 23px; margin-bottom: 10px; }
.project-content p { color: #616161; margin-bottom: 18px; }

.tag {
    display: inline-block;
    background: #eeeeec;
    padding: 5px 8px;
    margin: 3px 2px;
    border-radius: 4px;
    font-size: 12px;
}

.project-stub {
    margin-top: 15px;
    color: #500000;
    font-size: 13px;
    font-weight: 700;
}

.engineering-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.engineering-card {
    border-top: 3px solid #500000;
    background: white;
    padding: 28px;
    min-height: 180px;
    box-shadow: 0 3px 12px rgba(0,0,0,.05);
}

.engineering-card h3 { margin-bottom: 12px; }
.engineering-card p { color: #626262; }

.dark {
    background: #17191c;
    color: white;
}

.dark .section-intro { color: #c8c8c8; }

.venture-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.venture {
    border: 1px solid #3d3f42;
    padding: 32px;
    border-radius: 8px;
}

.venture h3 { font-size: 26px; margin-bottom: 12px; }
.venture p { color: #c9c9c9; margin-bottom: 18px; }

.metric { display: inline-block; margin-right: 24px; margin-top: 12px; }
.metric strong { display: block; font-size: 25px; }
.metric span { font-size: 12px; color: #aaa; }

.contact { text-align: center; }
.contact h2 { font-size: 42px; }
.contact p { color: #666; margin-bottom: 28px; }

footer {
    background: #101113;
    color: #999;
    padding: 25px;
    text-align: center;
    font-size: 13px;
}

/* Projects index */
.projects-page-hero {
    padding: 95px 10% 70px;
    background: #17191c;
    color: white;
}

.projects-page-hero .section-label { color: #dbbfc4; }
.projects-page-hero h1 { font-size: 58px; line-height: 1.05; margin-bottom: 18px; }
.projects-page-hero p { max-width: 760px; color: #c8c8c8; font-size: 18px; }

.project-section {
    padding-top: 65px;
    padding-bottom: 70px;
}

.project-section.alt { background: #ececea; }

.project-section-header {
    max-width: 780px;
    margin-bottom: 35px;
}

.main-project-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.team-card {
    background: white;
    border-top: 3px solid #500000;
    border-radius: 7px;
    padding: 28px;
    border-left: 1px solid #e3e3df;
    border-right: 1px solid #e3e3df;
    border-bottom: 1px solid #e3e3df;
}

.team-card h3 {
    font-size: 21px;
    margin-bottom: 10px;
}

.team-card p { color: #626262; margin-bottom: 12px; }

.earlier-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.earlier-card {
    background: white;
    border: 1px solid #deded9;
    border-radius: 8px;
    overflow: hidden;
    min-height: 100%;
}

.earlier-card .project-media { height: 170px; }
.earlier-card .project-content { padding: 19px; }
.earlier-card h3 { font-size: 18px; }
.earlier-card p { font-size: 14px; margin-bottom: 10px; }

/* Project detail */
.project-detail-hero {
    background: #17191c;
    color: white;
    padding: 80px 10% 65px;
}

.project-detail-hero h1 {
    font-size: 56px;
    line-height: 1.05;
    margin-bottom: 18px;
}

.project-detail-hero p {
    max-width: 820px;
    color: #c8c8c8;
    font-size: 18px;
}

.project-detail {
    max-width: 1200px;
    margin: 0 auto;
    padding: 65px 7% 85px;
}

.back-link {
    display: inline-block;
    margin-bottom: 28px;
    color: #500000;
    font-weight: 700;
    text-decoration: none;
}

.hero-photo {
    width: 100%;
    height: 470px;
    border-radius: 10px;
    overflow: hidden;
    background: #ddd;
    margin-bottom: 24px;
}

.hero-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-cluster {
    display: grid;
    grid-template-columns: 1.35fr .65fr .65fr;
    grid-template-rows: 210px 210px;
    gap: 14px;
    margin-bottom: 55px;
}

.photo-cluster figure {
    overflow: hidden;
    border-radius: 8px;
    background: #ddd;
    position: relative;
}

.photo-cluster figure:first-child { grid-row: 1 / span 2; }

.photo-cluster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.photo-cluster figcaption,
.gallery-grid figcaption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 22px 12px 9px;
    background: linear-gradient(transparent, rgba(0,0,0,.72));
    color: white;
    font-size: 12px;
}

.project-detail-grid {
    display: grid;
    grid-template-columns: 1.45fr .55fr;
    gap: 55px;
    align-items: start;
}

.project-detail h2 { font-size: 34px; margin-bottom: 18px; }
.project-detail h3 { margin-top: 30px; margin-bottom: 10px; font-size: 22px; }
.project-detail p, .project-detail li { color: #505050; font-size: 17px; }
.project-detail p { margin-bottom: 18px; }
.project-detail ul { padding-left: 22px; margin-bottom: 24px; }
.project-detail li { margin-bottom: 8px; }

.project-sidebar {
    background: white;
    border: 1px solid #deded9;
    border-top: 3px solid #500000;
    border-radius: 8px;
    padding: 25px;
}

.project-sidebar h3 { margin-top: 0; font-size: 18px; }

.project-fact {
    padding: 14px 0;
    border-bottom: 1px solid #ececea;
    color: #555;
}

.project-fact:last-child { border-bottom: none; }

.project-fact strong {
    display: block;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #500000;
    margin-bottom: 3px;
}

.gallery-heading { margin-top: 65px; }

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.gallery-grid figure {
    height: 280px;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    background: #ddd;
}

.gallery-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-block {
    margin-top: 45px;
    background: #ececea;
    border-radius: 10px;
    padding: 25px;
}

.video-block video {
    width: 100%;
    max-height: 620px;
    background: #111;
    border-radius: 7px;
}

.small-note {
    color: #777;
    font-size: 14px;
    margin-top: 8px;
}

@media(max-width: 1000px) {
    .main-project-grid, .team-grid { grid-template-columns: repeat(2, 1fr); }
    .earlier-grid { grid-template-columns: repeat(2, 1fr); }
    .photo-cluster {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 280px 200px 200px;
    }
    .photo-cluster figure:first-child { grid-column: 1 / span 2; grid-row: auto; }
}

@media(max-width: 760px) {
    .nav-links { display: none; }
    .hero { padding-left: 7%; padding-right: 7%; }
    .hero h1 { font-size: 47px; }
    section { padding-left: 7%; padding-right: 7%; }
    .about-grid, .engineering-grid, .venture-grid,
    .main-project-grid, .team-grid, .earlier-grid,
    .project-detail-grid, .gallery-grid {
        grid-template-columns: 1fr;
    }
    .about-photo {
        max-width: 420px;
        margin: 0 auto;
    }
    .projects-page-hero h1, .project-detail-hero h1 { font-size: 42px; }
    .hero-photo { height: 320px; }
    .photo-cluster {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(4, 230px);
    }
    .photo-cluster figure:first-child { grid-column: auto; }
}


/* =========================================================
   FALLOUT POWER FIST — POLISHED PROJECT PAGE
   ========================================================= */

.powerfist-page .pf-header {
    padding-top: 72px;
    padding-bottom: 58px;
}

.powerfist-page .pf-header h1 {
    max-width: 900px;
}

.powerfist-page .pf-page {
    max-width: 1180px;
    padding-top: 48px;
}

.powerfist-page .pf-intro {
    padding: 0;
    display: grid;
    grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.2fr);
    gap: 34px;
    align-items: stretch;
}

.powerfist-page .pf-cover-card {
    background: #e7e7e3;
    border-radius: 12px;
    overflow: hidden;
    min-height: 560px;
    box-shadow: 0 5px 18px rgba(0,0,0,0.07);
}

.powerfist-page .pf-cover-card img {
    width: 100%;
    height: 100%;
    min-height: 560px;
    object-fit: cover;
    object-position: 50% 46%;
    display: block;
}

.powerfist-page .pf-overview-card {
    background: white;
    border: 1px solid #deded9;
    border-top: 4px solid #500000;
    border-radius: 12px;
    padding: 38px;
    box-shadow: 0 5px 18px rgba(0,0,0,0.045);
}

.powerfist-page .pf-overview-card h2 {
    font-size: 35px;
    line-height: 1.12;
    margin-bottom: 20px;
}

.powerfist-page .pf-overview-card p {
    color: #555;
    font-size: 17px;
    margin-bottom: 18px;
}

.powerfist-page .pf-facts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 28px;
}

.powerfist-page .pf-fact {
    background: #f2f2ef;
    border-radius: 7px;
    padding: 15px 16px;
}

.powerfist-page .pf-fact span {
    display: block;
    color: #777;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 10px;
    font-weight: 700;
    margin-bottom: 3px;
}

.powerfist-page .pf-fact strong {
    display: block;
    font-size: 14px;
    line-height: 1.35;
}

.powerfist-page .pf-section {
    padding: 0;
    margin-top: 82px;
}

.powerfist-page .pf-section-heading {
    max-width: 760px;
    margin-bottom: 30px;
}

.powerfist-page .pf-section-heading h2,
.powerfist-page .pf-story-copy h2 {
    font-size: 36px;
    margin-bottom: 12px;
}

.powerfist-page .pf-section-heading p {
    color: #666;
    font-size: 17px;
}

.powerfist-page .pf-gallery {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 18px;
}

.powerfist-page .pf-media {
    margin: 0;
    background: white;
    border: 1px solid #deded9;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,0.045);
}

.powerfist-page .pf-media.pf-landscape {
    grid-column: span 7;
}

.powerfist-page .pf-media.pf-portrait {
    grid-column: span 5;
}

.powerfist-page .pf-media img {
    display: block;
    width: 100%;
    background: #e8e8e5;
}

.powerfist-page .pf-media.pf-landscape img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.powerfist-page .pf-media.pf-portrait img {
    aspect-ratio: 4 / 3;
    object-fit: contain;
    padding: 12px;
}

.powerfist-page .pf-media figcaption {
    position: static;
    background: white;
    color: #555;
    padding: 15px 17px 17px;
    font-size: 14px;
    line-height: 1.4;
}

.powerfist-page .pf-media figcaption strong {
    color: #202020;
    display: block;
    margin-bottom: 2px;
}

.powerfist-page .pf-media figcaption span {
    color: #686868;
}

.powerfist-page .pf-story-section {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
    gap: 42px;
    align-items: center;
    background: #ececea;
    border-radius: 12px;
    padding: 42px;
}

.powerfist-page .pf-story-list {
    padding-left: 22px;
    margin: 20px 0 26px;
}

.powerfist-page .pf-story-list li {
    margin-bottom: 10px;
    color: #4f4f4f;
    font-size: 16px;
}

.powerfist-page .pf-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.powerfist-page .pf-tools span {
    background: white;
    border: 1px solid #dadad6;
    border-radius: 999px;
    padding: 7px 11px;
    font-size: 12px;
    font-weight: 700;
}

.powerfist-page .pf-bench-card {
    margin: 0;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

.powerfist-page .pf-bench-card img {
    width: 100%;
    max-height: 480px;
    object-fit: contain;
    background: #deded9;
    display: block;
}

.powerfist-page .pf-bench-card figcaption {
    padding: 12px 15px 14px;
    color: #666;
    font-size: 13px;
}

.powerfist-page .pf-video-section {
    margin-bottom: 20px;
}

.powerfist-page .pf-video-wrap {
    max-width: 820px;
    margin: 0 auto;
    background: #111;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(0,0,0,0.12);
}

.powerfist-page .pf-video-wrap video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    height: auto;
    object-fit: contain;
    background: #111;
}

@media(max-width: 900px) {
    .powerfist-page .pf-intro,
    .powerfist-page .pf-story-section {
        grid-template-columns: 1fr;
    }

    .powerfist-page .pf-cover-card,
    .powerfist-page .pf-cover-card img {
        min-height: 0;
    }

    .powerfist-page .pf-cover-card img {
        aspect-ratio: 4 / 3;
        object-fit: contain;
        background: #e7e7e3;
    }

    .powerfist-page .pf-media.pf-landscape,
    .powerfist-page .pf-media.pf-portrait {
        grid-column: span 6;
    }
}

@media(max-width: 650px) {
    .powerfist-page .pf-overview-card {
        padding: 26px 22px;
    }

    .powerfist-page .pf-facts {
        grid-template-columns: 1fr;
    }

    .powerfist-page .pf-gallery {
        grid-template-columns: 1fr;
    }

    .powerfist-page .pf-media.pf-landscape,
    .powerfist-page .pf-media.pf-portrait {
        grid-column: auto;
    }

    .powerfist-page .pf-story-section {
        padding: 28px 22px;
    }

    .powerfist-page .pf-section {
        margin-top: 60px;
    }
}


/* =========================================================
   POWER FIST — CLICKABLE IMAGE GALLERY
   ========================================================= */

.powerfist-page .pf-gallery-viewer {
    margin-bottom: 48px;
}

.powerfist-page .pf-main-image-wrap {
    width: 100%;
    max-width: 980px;
    height: min(62vw, 610px);
    min-height: 420px;
    margin: 0 auto;
    border-radius: 12px;
    overflow: hidden;
    background: #e5e5e1;
    border: 1px solid #d8d8d3;
    box-shadow: 0 7px 24px rgba(0,0,0,0.08);
}

.powerfist-page .pf-main-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: opacity .16s ease;
}

.powerfist-page .pf-main-image.is-changing {
    opacity: .25;
}

.powerfist-page .pf-main-caption {
    max-width: 980px;
    margin: 13px auto 0;
    color: #666;
    font-size: 14px;
    text-align: center;
    min-height: 22px;
}

.powerfist-page .pf-thumbnails {
    max-width: 980px;
    margin: 18px auto 0;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
}

.powerfist-page .pf-thumb {
    appearance: none;
    border: 2px solid transparent;
    background: #e7e7e3;
    padding: 0;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.powerfist-page .pf-thumb:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 14px rgba(0,0,0,.10);
}

.powerfist-page .pf-thumb.active {
    border-color: #500000;
    box-shadow: 0 0 0 1px #500000;
}

.powerfist-page .pf-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.powerfist-page .pf-thumb[data-fit="contain"] img {
    object-fit: contain;
    padding: 5px;
    background: #ecece8;
}

.powerfist-page .pf-gallery-hint {
    text-align: center;
    color: #888;
    font-size: 12px;
    margin-top: 8px;
}

.powerfist-page .pf-overview-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr);
    gap: 42px;
    align-items: start;
}

.powerfist-page .pf-overview-copy {
    background: white;
    border: 1px solid #deded9;
    border-radius: 10px;
    padding: 34px;
}

.powerfist-page .pf-overview-copy h2 {
    font-size: 34px;
    margin-bottom: 18px;
}

.powerfist-page .pf-overview-copy p {
    color: #555;
    font-size: 17px;
    margin-bottom: 17px;
}

.powerfist-page .pf-overview-copy h3 {
    margin-top: 28px;
    margin-bottom: 10px;
    font-size: 22px;
}

.powerfist-page .pf-overview-copy ul {
    padding-left: 22px;
}

.powerfist-page .pf-overview-copy li {
    color: #505050;
    margin-bottom: 8px;
}

.powerfist-page .pf-snapshot {
    background: white;
    border: 1px solid #deded9;
    border-top: 3px solid #500000;
    border-radius: 9px;
    padding: 25px;
}

.powerfist-page .pf-snapshot h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.powerfist-page .pf-snapshot-row {
    padding: 14px 0;
    border-bottom: 1px solid #ececea;
}

.powerfist-page .pf-snapshot-row:last-child {
    border-bottom: none;
}

.powerfist-page .pf-snapshot-row strong {
    display: block;
    color: #500000;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 3px;
}

@media(max-width: 900px) {
    .powerfist-page .pf-thumbnails {
        grid-template-columns: repeat(3, 1fr);
    }

    .powerfist-page .pf-main-image-wrap {
        height: min(75vw, 560px);
        min-height: 330px;
    }

    .powerfist-page .pf-overview-layout {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 560px) {
    .powerfist-page .pf-thumbnails {
        grid-template-columns: repeat(2, 1fr);
    }

    .powerfist-page .pf-main-image-wrap {
        height: 72vw;
        min-height: 260px;
    }

    .powerfist-page .pf-overview-copy {
        padding: 26px 22px;
    }
}


/* =========================================================
   REUSABLE CLICKABLE PROJECT GALLERY
   ========================================================= */

.project-gallery-viewer {
    margin: 0 0 54px;
}

.project-gallery-main {
    width: 100%;
    max-width: 980px;
    height: min(62vw, 610px);
    min-height: 420px;
    margin: 0 auto;
    border-radius: 12px;
    overflow: hidden;
    background: #e7e7e3;
    border: 1px solid #d7d7d2;
    box-shadow: 0 7px 24px rgba(0,0,0,.08);
}

.project-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    transition: opacity .16s ease;
}

.project-gallery-main img.is-changing {
    opacity: .25;
}

.project-gallery-caption {
    max-width: 980px;
    margin: 13px auto 0;
    text-align: center;
    color: #666;
    font-size: 14px;
    min-height: 22px;
}

.project-gallery-thumbs {
    max-width: 980px;
    margin: 18px auto 0;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
}

.project-gallery-thumb {
    appearance: none;
    padding: 0;
    border: 2px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    background: #e7e7e3;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.project-gallery-thumb:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 14px rgba(0,0,0,.10);
}

.project-gallery-thumb.active {
    border-color: #500000;
    box-shadow: 0 0 0 1px #500000;
}

.project-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.project-gallery-thumb.contain img {
    object-fit: contain;
    padding: 5px;
    background: #eeeeea;
}

.project-gallery-hint {
    margin-top: 8px;
    text-align: center;
    color: #888;
    font-size: 12px;
}

.project-page-two-col {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr);
    gap: 42px;
    align-items: start;
}

.project-copy-card {
    background: white;
    border: 1px solid #deded9;
    border-radius: 10px;
    padding: 34px;
}

.project-copy-card h2 {
    font-size: 34px;
    margin-bottom: 18px;
}

.project-copy-card h3 {
    font-size: 22px;
    margin: 28px 0 10px;
}

.project-copy-card p,
.project-copy-card li {
    color: #505050;
    font-size: 17px;
}

.project-copy-card p {
    margin-bottom: 17px;
}

.project-copy-card ul {
    padding-left: 22px;
}

.project-copy-card li {
    margin-bottom: 8px;
}

.project-snapshot-card {
    background: white;
    border: 1px solid #deded9;
    border-top: 3px solid #500000;
    border-radius: 9px;
    padding: 25px;
}

.project-snapshot-card h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.project-snapshot-row {
    padding: 14px 0;
    border-bottom: 1px solid #ececea;
}

.project-snapshot-row:last-child {
    border-bottom: none;
}

.project-snapshot-row strong {
    display: block;
    color: #500000;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 3px;
}

.project-video-section {
    margin-top: 68px;
}

.project-video-wrap {
    max-width: 820px;
    margin: 22px auto 0;
    background: #111;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(0,0,0,.12);
}

.project-video-wrap video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    height: auto;
    object-fit: contain;
    background: #111;
}

@media(max-width: 900px) {
    .project-gallery-thumbs {
        grid-template-columns: repeat(3, 1fr);
    }

    .project-gallery-main {
        height: min(75vw, 560px);
        min-height: 330px;
    }

    .project-page-two-col {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 560px) {
    .project-gallery-thumbs {
        grid-template-columns: repeat(2, 1fr);
    }

    .project-gallery-main {
        height: 72vw;
        min-height: 260px;
    }

    .project-copy-card {
        padding: 26px 22px;
    }
}


/* =========================================================
   POWER FIST — COMPACT CLICKABLE GALLERY
   ========================================================= */

.powerfist-page .project-gallery-viewer {
    max-width: 720px;
    margin: 0 auto 44px;
}

.powerfist-page .project-gallery-main {
    width: 100%;
    max-width: 680px;
    height: 360px;
    min-height: 0;
    margin: 0 auto;
    border-radius: 10px;
}

.powerfist-page .project-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #e7e7e3;
}

.powerfist-page .project-gallery-caption {
    max-width: 680px;
    margin: 9px auto 0;
    font-size: 13px;
    min-height: 18px;
}

.powerfist-page .project-gallery-thumbs {
    max-width: 680px;
    margin: 12px auto 0;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.powerfist-page .project-gallery-thumb {
    flex: 0 0 100px;
    width: 100px;
    height: 75px;
    aspect-ratio: auto;
    border-radius: 7px;
}

.powerfist-page .project-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.powerfist-page .project-gallery-thumb.contain img {
    object-fit: contain;
    padding: 3px;
}

.powerfist-page .project-gallery-hint {
    margin-top: 6px;
    font-size: 11px;
}

.powerfist-page .project-page-two-col {
    margin-top: 10px;
}

.powerfist-page .project-video-wrap {
    max-width: 680px;
}

@media(max-width: 760px) {
    .powerfist-page .project-gallery-viewer {
        max-width: 100%;
    }

    .powerfist-page .project-gallery-main {
        max-width: 100%;
        height: 52vw;
        min-height: 260px;
        max-height: 360px;
    }

    .powerfist-page .project-gallery-thumbs {
        max-width: 100%;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 5px;
    }

    .powerfist-page .project-gallery-thumb {
        flex-basis: 92px;
        width: 92px;
        height: 69px;
    }
}

@media(max-width: 480px) {
    .powerfist-page .project-gallery-main {
        height: 58vw;
        min-height: 230px;
    }

    .powerfist-page .project-gallery-thumb {
        flex-basis: 82px;
        width: 82px;
        height: 62px;
    }
}


/* =========================================================
   PROJECT PAGE SPACING — TIGHTER / CLEANER
   ========================================================= */

/* The global `section` rule adds large padding. Project-detail sections need
   their own tighter spacing so galleries, text, and videos flow together. */
.project-detail .project-gallery-viewer,
.project-detail .project-page-two-col,
.project-detail .project-video-section,
.project-detail .pf-section,
.project-detail .pf-video-section {
    padding: 0;
}

/* Gallery -> text */
.project-detail .project-gallery-viewer {
    margin-bottom: 28px;
}

/* Overview/text block */
.project-detail .project-page-two-col {
    margin-top: 0;
    margin-bottom: 0;
}

/* Text -> video */
.project-detail .project-video-section {
    margin-top: 42px;
    margin-bottom: 8px;
}

/* Reduce extra spacing inside the project page overall */
.project-detail {
    padding-top: 48px;
    padding-bottom: 65px;
}

/* Keep headings from adding unnecessary vertical distance */
.project-detail .project-video-section > .section-label {
    margin-bottom: 6px;
}

.project-detail .project-video-section > h2 {
    margin-bottom: 10px;
}

/* Power Fist page-specific spacing */
.powerfist-page .project-gallery-viewer {
    margin-bottom: 28px;
}

.powerfist-page .project-page-two-col {
    margin-top: 0;
}

.powerfist-page .project-video-section {
    margin-top: 42px;
}

/* Mobile: keep it compact but readable */
@media(max-width: 760px) {
    .project-detail {
        padding-top: 36px;
        padding-bottom: 50px;
    }

    .project-detail .project-gallery-viewer {
        margin-bottom: 22px;
    }

    .project-detail .project-video-section {
        margin-top: 32px;
    }
}


/* =========================================================
   FINAL PROJECT PAGE SPACING OVERRIDE
   Force gallery, text, and video sections to sit closer together.
   ========================================================= */

/* Remove any inherited global section padding inside project pages. */
.project-detail > section {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

/* Gallery -> overview */
.project-detail > .project-gallery-viewer {
    margin-top: 0 !important;
    margin-bottom: 18px !important;
}

/* Overview block */
.project-detail > .project-page-two-col {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding: 0 !important;
}

/* Overview -> video */
.project-detail > .project-page-two-col + .project-video-section {
    margin-top: 30px !important;
}

/* Any video section inside a project page */
.project-detail > .project-video-section {
    padding: 0 !important;
    margin-bottom: 0 !important;
}

/* Pull the project content together a bit more overall */
.project-detail {
    padding-top: 32px !important;
    padding-bottom: 48px !important;
}

/* Slightly reduce internal card padding so the text section feels less oversized */
.project-copy-card {
    padding: 28px !important;
}

.project-snapshot-card {
    padding: 22px !important;
}

/* Reduce spacing above project video heading/player */
.project-video-section > .section-label {
    margin-bottom: 4px !important;
}

.project-video-section > h2 {
    margin-bottom: 8px !important;
}

.project-video-wrap {
    margin-top: 14px !important;
}

/* Power Fist keeps its compact gallery sizing */
.powerfist-page .project-gallery-viewer {
    margin-bottom: 18px !important;
}

.powerfist-page .project-page-two-col + .project-video-section {
    margin-top: 30px !important;
}

@media (max-width: 760px) {
    .project-detail > .project-gallery-viewer {
        margin-bottom: 14px !important;
    }

    .project-detail > .project-page-two-col + .project-video-section {
        margin-top: 24px !important;
    }

    .project-detail {
        padding-top: 24px !important;
        padding-bottom: 36px !important;
    }
}


/* RC Robots — paired testing videos */
.rc-video-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    max-width: 980px;
    margin: 14px auto 0;
}

.rc-video-grid .project-video-wrap {
    margin-top: 0 !important;
    max-width: 100%;
}

.rc-video-caption {
    margin: 8px 0 0;
    text-align: center;
    color: #666;
    font-size: 13px;
}

@media(max-width: 760px) {
    .rc-video-grid {
        grid-template-columns: 1fr;
    }
}
