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

html {
    background-image: linear-gradient(rgba(255,255,255,0.5), rgba(255,255,255,0.5)), url('Texturelabs_Paper_237XL.jpg');
    background-repeat: repeat;
    background-size: 500px 500px;
    background-color: #fff;
    min-height: 100vh;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: transparent;
    color: #333;
    line-height: 1.6;
    cursor: none;
}

a {
    cursor: none;
}

/* Custom cursor: a ring that follows the pointer. The outer element is
   positioned via script.js (transform: translate), so the hover grow/fill
   effect lives on the inner ring instead, to avoid both trying to control
   `transform` at once. */
.custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 24px;
    height: 24px;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.custom-cursor.is-visible {
    opacity: 1;
}

.custom-cursor-ring {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #7387B7;
    box-sizing: border-box;
    transition: transform 0.15s ease, background-color 0.15s ease;
}

.custom-cursor.is-hover .custom-cursor-ring {
    transform: scale(1.35);
    background-color: #7387B7;
}

/* Navigation */
.navbar {
    background-color: transparent;
    padding: 2rem 3rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    position: relative;
    text-decoration: none;
    color: #333;
    font-size: 0.75rem;
    letter-spacing: 0.1rem;
    padding-bottom: 0.25rem;
}

.nav-logo.active::after {
    content: "";
    position: absolute;
    left: -6%;
    bottom: -0.4rem;
    width: 112%;
    height: 8px;
    background: url("divider.svg") no-repeat center / 100% 100%;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: #333;
    font-size: 0.75rem;
    letter-spacing: 0.1rem;
    transition: opacity 0.3s ease;
}

.nav-menu a:hover {
    opacity: 0.6;
}

.nav-menu a {
    position: relative;
}

.nav-menu a.active::after {
    content: "";
    position: absolute;
    left: -6%;
    bottom: -0.5rem;
    width: 112%;
    height: 8px;
    background: url("nav_underline.svg") no-repeat center / 100% 100%;
}

/* Hero Section */
.hero {
    max-width: 1350px;
    margin: 0 auto;
    padding: 1rem 5rem;
    position: relative;
    min-height: 750px;
    /* No overflow clipping here anymore - the .ink-drag-layer below handles
       that, with generous headroom above so the hand/ink can move freely,
       including over the navbar, while still cutting off at the bottom. */
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 600px;
}

.hero-title {
    font-size: 100px;
    letter-spacing: 35%;
    white-space: nowrap;
    color: #000;
    font-weight: 300;
}

.hero-subtitle {
    font-size: 32px;
    letter-spacing: 24%;
    margin-bottom: 3rem;
    font-weight: normal;
    white-space: nowrap;
}

.hero-quote {
    position: absolute;
    bottom: 1rem;
    left: 0;
    width: 100%;
    font-size: 16px;
    letter-spacing: 5%;
    text-align: center;
    z-index: 10;
}

.hero-illustration {
    position: absolute;
    right: 15%;
    top: 0;
    width: 40%;
    height: 550px;
    z-index: 1;
    /* Placeholder for illustration */
}

.gibbon {
    height: 750px;
}

/* Wraps the ink canvas and draggable hand. Extends well above the hero's
   own top edge (and above the navbar) and out to both sides, so the hand
   can be dragged freely in every direction except the bottom, where this
   layer's own edge lines up exactly with the hero's bottom - keeping the
   ink/hand from ever being dragged over the featured-work section below.
   Height is set in JS to track the hero's actual rendered height. */
.ink-drag-layer {
    position: absolute;
    top: -600px;
    left: -300px;
    width: calc(100% + 600px);
    overflow: hidden;
    z-index: 150; /* above the navbar (100) so the hand can be dragged on top of it */
    pointer-events: none; /* let clicks pass through to the nav/hero beneath, except on the hand itself */
}

.hand-gibbon {
    position: absolute;
    /* top/left are set in JS */
    height: 300px;
    cursor: none;
    user-select: none;
    touch-action: none;
    pointer-events: auto;
}

.ink-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Me Page */
.me-section {
    max-width: 1350px;
    margin: 3rem auto 0;
    padding: 1rem 5rem 8rem;
    position: relative;
    min-height: 500px;
}

.me-columns {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 2rem;
    position: relative;
    z-index: 10;
}

.me-bio {
    max-width: 480px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.me-photo-frame {
    width: 380px;
    aspect-ratio: 1 / 1;
    flex-shrink: 0;
    background-color: #efefef;
}

.me-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
}

.me-illustration {
    position: absolute;
    left: 2%;
    top: 62%;
    width: 300px;
    z-index: 1;
}

.me-arrow-img {
    display: block;
    width: 100%;
    height: auto;
    margin-left: 500px;
    margin-top: 70px;
}

/* Same drag-and-draw mechanic as the homepage hero, scoped to this
   section: .me-arrow-img is the fixed reference the hand stays anchored
   to (in place of the gibbon), and .me-hand is the draggable pen. */
.me-drag-layer {
    position: absolute;
    top: -250px;
    left: -200px;
    width: calc(100% + 400px);
    overflow: hidden;
    z-index: 150;
    pointer-events: none;
}

.me-hand {
    position: absolute;
    height: 220px;
    margin-left: 250px;
    rotate: 15deg;
    cursor: none;
    user-select: none;
    touch-action: none;
    pointer-events: auto;
}

.me-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Featured Work Section */
.featured-work {
    max-width: 1400px;
    margin: 3rem auto;
    padding: 5rem;
    border-top: 1px solid #ddd;
    position: relative;
}

.featured-star {
    position: absolute;
    top: 30rem;
    right: 2rem;
    width: 300px;
    rotate: 30deg;
    height: auto;
    opacity: 0.7;
    z-index: 0;
    pointer-events: none;
}

.section-title {
    font-size: 1.4rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    color: #1a1a1a;
    display: inline-block;
}

.featured-divider {
    display: block;
    width: 140px;
    height: auto;
    margin-top: -4rem;
}

.work-grid {
    position: relative;
    width: 860px;
    height: 560px;
    margin: 4rem auto;
    margin-bottom: -2rem;
}

.work-item {
    position: absolute;
    width: 340px;
    height: 430px;
}

.work-card {
    display: block;
    background-color: white;
    border: 8px solid #fff;
    border-bottom-width: 80px;
    height: 100%;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    text-decoration: none;
    color: inherit;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.work-item:hover {
    z-index: 20;
}

.work-item:hover .work-card {
    transform: scale(1.08);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.22);
}

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

.work-card-img-contain {
    object-fit: contain;
}

.work-card-caption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: -72px;
    height: 64px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    text-align: center;
    padding: 0 0.5rem;
}

.work-card-caption-title {
    font-size: 0.8rem;
    letter-spacing: 0.06rem;
    text-transform: uppercase;
    font-weight: 600;
    color: #1a1a1a;
}

.work-card-caption-subtitle {
    font-size: 0.65rem;
    letter-spacing: 0.04rem;
    color: #999;
}

.item-1 {
    top: 0;
    left: -50px;
    transform: rotate(-7deg);
    z-index: 1;
}

.item-2 {
    top: 190px;
    left: 200px;
    transform: rotate(5deg);
    z-index: 2;
}

.item-3 {
    top: 40px;
    left: 600px;
    transform: rotate(-5deg);
    z-index: 1;
}

/* Pushpins */
.work-pin {
    position: absolute;
    width: 40px;
    height: auto;
    top: -20px;
    left: 50%;
    transform: translateX(-50%) rotate(-6deg);
    z-index: 10;
    pointer-events: none;
}

/* Footer */
.footer {
    background-color: transparent;
    padding: 3rem;
    margin-top: 4rem;
    border-top: 1px solid #ddd;
}

.footer-links {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: flex-end;
    gap: 3rem;
}

.footer-links a {
    text-decoration: none;
    color: #333;
    font-size: 0.75rem;
    letter-spacing: 0.1rem;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 0.6;
}

/* Brilliance Exposed Page Styles */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 3rem;
}

.project-title {
    font-size: 64px;
    letter-spacing: 35%;
    font-weight: 300;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

.project-quote {
    font-size: 1.1rem;
    font-style: italic;
    color: #666;
    margin-bottom: 1rem;
}

.project-subtitle {
    font-size: 16px;
    letter-spacing: 0.1rem;
    color: #666;
    font-weight: 400;
    line-height: 1.8;
    margin-bottom: 4rem;
}

.project-meta {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 4rem;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.meta-label {
    font-size: 0.65rem;
    letter-spacing: 0.12rem;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
}

.meta-value {
    font-size: 0.9rem;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
    font-weight: 400;
}

.hero-img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    border-radius: 12px;
}

.content-section {
    margin: 2.5rem 0;
    padding: 1.5rem 0;
}

#concept,
#problem {
    margin-bottom: 4rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
}

.back-link {
    font-size: 0.75rem;
    letter-spacing: 0.1rem;
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 400;
    transition: opacity 0.3s ease;
}

.back-link:hover {
    opacity: 0.6;
}

.inline-link {
    color: #7387B7;
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 600;
    transition: opacity 0.3s ease;
}

.inline-link:hover {
    opacity: 0.7;
}

.citation-link {
    color: #7387B7;
    text-decoration: none;
    border-bottom: 1px solid rgba(115, 135, 183, 0.4);
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.citation-link:hover {
    border-bottom-color: #7387B7;
    background-color: rgba(115, 135, 183, 0.1);
}

.source-item {
    scroll-margin-top: 110px;
}

.citation-link:target,
.source-item:target {
    background-color: rgba(115, 135, 183, 0.15);
    border-radius: 4px;
}

.ballot-cta {
    text-align: center;
    margin: 2.5rem 0;
}

.ballot-cta-text {
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
    margin-bottom: 1.25rem;
    text-transform: uppercase;
}

.ballot-button {
    display: inline-block;
    padding: 0.75rem 2rem;
    border-radius: 4px;
    font-size: 0.75rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    background-color: #1a1a1a;
    color: #fff;
    text-decoration: none;
    margin-top: 1rem;
}

.ballot-button:hover {
    background-color: #7387B7;
    border: none;
    color: #fff;
}

.ballot-cta-highlight {
    position: relative;
    background-color: #e4e4e4;
    padding: 2.5rem 2rem;
    border-radius: 8px;
    width: 600px;
    margin: 3.5rem auto;
}

.ballot-cta-pin {
    position: absolute;
    top: -26px;
    right: 8%;
    width: 60px;
    height: auto;
    transform: rotate(28deg);
    pointer-events: none;
}

.project-section-title {
    font-size: 0.8rem;
    letter-spacing: 0.2rem;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

.section-content {
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    gap: 5rem;
    align-items: flex-start;
}

.left-column {
    position: sticky;
    top: 100px;
}

.subsection-title {
    font-size: 0.7rem;
    letter-spacing: 0.15rem;
    font-weight: 600;
    color: #999;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.approach-list {
    list-style: none;
}

.approach-list li {
    margin-bottom: 1rem;
}

.approach-list a {
    position: relative;
    display: inline-block;
    font-size: 0.8rem;
    letter-spacing: 0.08rem;
    color: #bbb;
    font-weight: 400;
    text-decoration: none;
    transition: color 0.3s ease;
}

.approach-list a::after {
    content: "";
    position: absolute;
    left: -4%;
    bottom: -0.35rem;
    width: 108%;
    height: 10px;
    background: url("nav_underline.svg") no-repeat center / 100% 100%;
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.approach-list a.active {
    color: #1a1a1a;
}

.approach-list a.active::after {
    opacity: 1;
    transform: scale(1);
}

.problem-heading {
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 7%;
    color: #1a1a1a;
}

.problem-heading.problem-heading-body {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
}

.cvs-problem-heading {
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 7%;
    color: #1a1a1a;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.problem-text {
    font-size: .85rem;
    color: #1a1a1a;
    font-weight: 400;
    letter-spacing: 7%;
}

.approach-question {
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 7%;
    color: #1a1a1a;
}

.approach-question + .approach-question {
    margin-top: 1.5rem;
}

.emphasis-text {
    font-size: 1.1rem;
    font-weight: 600;
}

.section-divider {
    display: block;
    width: 120px;
    height: auto;
    margin: 1.5rem auto;
}

.loading-indicator {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 0;
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    color: #666;
}

.loading-spinner {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    border: 2px solid #ddd;
    border-top-color: #7387B7;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-error {
    padding: 1rem 0;
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    color: #999;
}

.stats-table-wrapper {
    margin-top: 1rem;
    border: 1px solid #ccc;
    border-radius: 12px;
    overflow: hidden;
}

.stats-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
    letter-spacing: 0.03rem;
    color: #1a1a1a;
}

.stats-table th,
.stats-table td {
    border: 1px solid #ccc;
    border-top: none;
    border-left: none;
    padding: 0.5rem 0.75rem;
    text-align: left;
}

.stats-table thead tr:first-child th {
    border-top: none;
}

.stats-table tr th:last-child,
.stats-table tr td:last-child {
    border-right: none;
}

.stats-table thead th {
    background-color: #f0f0f0;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.08rem;
    color: #666;
}

.project-text {
    font-size: 0.85rem;
    color: #1a1a1a;
    letter-spacing: 0.05rem;
    margin-top: 0.8rem;
    margin-bottom: 1rem;
}

.research-section {
    margin-bottom: 4rem;
}

.research-subtitle {
    font-size: 0.75rem;
    letter-spacing: 0.15rem;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.wireframe-subtitle {
    font-size: 0.75rem;
    letter-spacing: 0.15rem;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.content-list {
    margin-bottom: 1.5rem;
}

.content-list li {
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
    margin-left: 1rem;
}

.results-table-wrapper {
    overflow-x: auto;
    margin: 1.5rem 0;
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.results-table th,
.results-table td {
    text-align: left;
    padding: 0.6rem 1rem;
    border-bottom: 1px solid #e0e0e0;
    white-space: nowrap;
}

.results-table th {
    font-size: 0.7rem;
    letter-spacing: 0.08rem;
    text-transform: uppercase;
    color: #999;
    font-weight: 600;
}

.results-table td {
    color: #1a1a1a;
}

.results-table tbody tr:first-child td {
    font-weight: 600;
}

.rubric-table {
    table-layout: fixed;
    width: 100%;
}

.rubric-table th,
.rubric-table td {
    white-space: normal;
    overflow-wrap: break-word;
    vertical-align: top;
}

.rubric-table th:first-child,
.rubric-table td:first-child {
    width: 16%;
}

.rubric-table th:not(:first-child),
.rubric-table td:not(:first-child) {
    width: 28%;
}

.rubric-table tbody tr td {
    font-weight: 400;
}

.rubric-table tbody tr:first-child td:not(:first-child) {
    font-weight: 400;
}

.rubric-table td:first-child {
    font-weight: 600;
}

.features-box {
    background-color: #fff;
    border-radius: 8px;
    max-width: 400px;
    margin: 2rem auto;
    padding: 1.5rem 2.5rem;
}

.features-box .research-subtitle {
    text-align: center;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.features-box .content-list {
    margin-bottom: 0;
}

.features-box .content-list li {
    margin-bottom: 1rem;
}

.features-box .content-list li:last-child {
    margin-bottom: 0;
}

.feedback-row {
    display: flex;
    gap: 2rem;
    max-width: 800px;
    margin: 1.5rem auto;
}

.feedback-box {
    background-color: #fff;
    flex: 1;
    border-radius: 8px;
    padding: 1.5rem 2rem;
    width: 500px;
}

.feedback-box-centered {
    margin: 0 auto;
}

/* Research tables on Brilliance Exposed: white tables with hairline
   dividers, where every heading sits in a darker block for contrast.
   All text matches the 0.85rem body bullets. */
.analysis-table {
    width: 100%;
    margin-top: 1.5rem;
    border-collapse: collapse;
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    table-layout: fixed;
}

.analysis-table td {
    width: 50%;
    padding: 0;
    vertical-align: top;
}

.analysis-pair thead td {
    background-color: #e6e4df;
    vertical-align: top;
}

.analysis-table tr + tr td {
    border-top: 1px solid #e0ded9;
}

.analysis-table td + td {
    border-left: 1px solid #e0ded9;
}

.analysis-head {
    background-color: #e6e4df;
    padding: 1rem 2rem;
}

/* Headings read as bold body text */
.analysis-head .research-subtitle {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
    margin-bottom: 0;
}

/* Long words wrap inside their cell instead of spilling into the next */
.analysis-table td,
.analysis-table th,
.applying-findings {
    overflow-wrap: break-word;
}

.analysis-question {
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    color: #666;
    margin-top: 0.25rem;
}

.analysis-source {
    color: #999;
}

.analysis-table .content-list,
.applying-findings .content-list {
    margin: 0;
    padding: 1.25rem 2rem 1.5rem;
}

.analysis-table .content-list li:last-child,
.applying-findings .content-list li:last-child {
    margin-bottom: 0;
}

.research-topics-intro {
    margin-top: 3rem;
}

/* Online research: four equal cards in one row, grey heading over a white list */
.research-cards {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    column-gap: 1.25rem;
    row-gap: 0;
    margin-top: 1.5rem;
}

/* Each card spans a heading row and a list row, so headings line up */
.research-card {
    display: grid;
    grid-row: span 2;
    grid-template-rows: subgrid;
    row-gap: 0;
    margin-bottom: 1.25rem;
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    overflow-wrap: break-word;
}

.research-card .analysis-head {
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    padding: 1.25rem 1.25rem;
}

.research-card .content-list {
    margin: 0;
    padding: 1.25rem 1.25rem 1.5rem;
}

.research-card .content-list li:last-child {
    margin-bottom: 0;
}

/* Sources: a plain wide white box */
.sources-section .analysis-sources {
    padding: 0.5rem 0 0 1.25rem;
}

.sources-link {
    color: #7387B7;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.research-sources {
    background-color: #fff;
    border-radius: 8px;
    padding: 1.25rem 1.5rem 0.25rem;
    overflow-wrap: break-word;
}

.research-sources .research-subtitle {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
    margin-bottom: 0;
}

.research-sources .analysis-sources {
    padding: 0.75rem 0 1.25rem 1.25rem;
}

@media (max-width: 1200px) {
    .research-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .research-cards {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Push pin holding the design goals note to the page */
.applying-findings {
    position: relative;
    overflow: visible !important;
}

.applying-findings > .analysis-head {
    border-radius: 8px 8px 0 0;
}

.push-pin {
    position: absolute;
    top: -54px;
    left: 72%;
    width: 60px;
    height: auto;
    transform: translateX(-50%) rotate(-8deg);
    pointer-events: none;
    z-index: 5;
}

.analysis-sources {
    margin: 0;
    padding: 1.25rem 1.5rem 1.5rem 2.75rem;
}

.analysis-sources li {
    font-size: 0.85rem;
    letter-spacing: 0.03rem;
    line-height: 1.6;
    color: #666;
    margin-bottom: 0.5rem;
    overflow-wrap: anywhere;
}

.analysis-sources a {
    color: #666;
}

.applying-findings {
    max-width: 100%;
    margin-top: 5rem;
    padding: 0;
    overflow: hidden;
}

/* Project pages: below laptop width the 250px side menu squeezes the
   content, so stack it above the content and keep only the back link */
@media (max-width: 1024px) {
    .section-content {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.5rem;
    }

    .left-column {
        position: static;
    }

    .left-column .approach-list {
        display: none;
    }
}

@media (max-width: 768px) {
    .analysis-table,
    .analysis-table tbody,
    .analysis-table tr,
    .analysis-table td {
        display: block;
        width: 100%;
    }

    /* Phones: flatten each pair so every heading sits right above its list */
    .analysis-pair {
        display: flex;
        flex-direction: column;
    }

    .analysis-pair thead,
    .analysis-pair tbody,
    .analysis-pair tr {
        display: contents;
    }

    .analysis-pair .col-a {
        order: 1;
    }

    .analysis-pair .col-b {
        order: 2;
    }

    .analysis-pair tbody td {
        border-top: none;
    }

    .analysis-table td + td {
        border-left: none;
        border-top: 1px solid #e0ded9;
    }

    .analysis-head {
        padding: 1rem 1.5rem;
    }

    .analysis-table .content-list,
    .applying-findings .content-list,
    .research-card .content-list {
        padding: 1.25rem 1.5rem;
    }
}

.feedback-box .content-list {
    margin-bottom: 0;
}

.ps-header {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1.25rem;
    margin: 1.5rem 0 0.75rem;
}

.ps-header span {
    font-size: 0.7rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    color: #999;
    text-align: center;
}

.ps-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.ps-pair {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 1.25rem;
}

.ps-box {
    background-color: #fff;
    border-radius: 8px;
    padding: 1rem 1.25rem;
}

.ps-box p {
    margin: 0;
}

.ps-arrow {
    font-size: 1.25rem;
    color: #999;
}

.competitive-analysis-placeholder {
    width: 100%;
    background-color: #d9d9d9;
    border-radius: 12px;
    overflow: hidden;
}

.wireframes-placeholder {
    background-color: transparent;
    border: none;
    padding: 0;
}

.wireframes-row {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    width: 100%;
    margin-top: 1.5rem;
}

.wireframes-row > * {
    min-width: 0;
}

.wireframes-row > img:first-child {
    flex: 0 1 31%;
}

.wireframes-row > .wireframe-stack {
    flex: 0 1 32%;
}

.wireframes-row > img:last-child {
    flex: 0 1 37%;
}

.wireframe-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 12px;
    
}

.wireframe-stack {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.research-img {
    width: 100%;
    height: auto;
    display: block;
}

.problem-flow {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 1.5rem 0;
}

.problem-flow-box {
    width: 300px;
    max-width: 100%;
    background-color: #e4e4e4;
    border-radius: 8px;
    padding: 1.5rem 2rem;
    font-size: 0.85rem;
    letter-spacing: 0.03rem;
    color: #1a1a1a;
    line-height: 1.6;
}

.problem-flow-arrow {
    align-self: center;
    width: 2px;
    height: 32px;
    background-color: #999;
    margin: 0.5rem 0;
    position: relative;
}

.problem-flow-arrow::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -1px;
    width: 8px;
    height: 8px;
    border-right: 2px solid #999;
    border-bottom: 2px solid #999;
    transform: translateX(-50%) rotate(45deg);
}

.design-flow-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin: 2rem 0;
}

.design-flow-item {
    text-align: center;
    width: 250px;
}

.design-flow-item img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
}

/* Chart grids (data-viz case studies): unlike .design-flow-grid, images
   fill their column (no fixed width cap) with a tighter gap, so multi-chart
   rows use more of the available width. */
.chart-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin: 2rem 0;
}

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

.chart-item {
    text-align: center;
    width: 100%;
}

.chart-item img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
}

.design-flow-item figcaption {
    margin-top: 0.75rem;
}

.design-wide-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
    margin: 1.5rem 0;
}

.design-pages-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem 1rem;
    align-items: start;
    margin: 2rem 0;
}

/* Numbered groups of screens in Our Designs on Brilliance Exposed */
.design-group {
    margin-top: 3.5rem;
}

.design-group-head {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #dcd9d3;
}

.design-group-num {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.1rem;
    color: #7387B7;
}

.design-group-title {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
    color: #1a1a1a;
}

.design-group .design-pages-grid {
    margin-top: 1.5rem;
}

.design-page figcaption {
    text-align: left;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

/* A pop-up shown at the same scale as the full-page screens: it covers
   roughly a third of the page width on the live site */
.design-page .design-popup-img {
    width: 33%;
    border-radius: 6px;
}

/* Revised designs: each screen centred, with a hand-drawn arrow
   annotation on either side pointing at what changed. --y is the
   height on the screen the arrow tip points to */
.revised-designs {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    margin: 2rem 0;
}

.revised-figure {
    width: 48%;
    margin: 0 auto;
}

.revised-frame {
    position: relative;
}

/* Each note is a row: the arrow tip touches the screen and the
   text sits out by the arrow's tail */
.revised-note {
    position: absolute;
    width: 54%;
    display: flex;
    gap: 0.5rem;
}

.revised-note p {
    flex: 1;
    font-size: 0.85rem;
    letter-spacing: 0.05rem;
    line-height: 1.6;
    color: #1a1a1a;
    margin: 0;
}

.revised-arrow {
    flex: none;
    width: 80px;
}

/* Left note: [text][arrow curling up-right]. The arrow sits at the
   bottom of the row; its tip is ~31px above the row's bottom, at --y */
.revised-note-left {
    right: calc(100% + 0.25rem);
    top: var(--y);
    transform: translateY(calc(-100% + 31px));
    align-items: flex-end;
    text-align: right;
}

.revised-note-left p {
    margin-bottom: 1.25rem;
}

/* Right note: text on top, indented so it starts over the arrow's
   tail; the arrow below points left at the screen. Its tip is ~18px
   above the note's bottom and sits at --y */
.revised-note-right {
    left: calc(100% + 0.25rem);
    top: var(--y);
    transform: translateY(calc(-100% + 18px));
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
}

.revised-note-right p {
    padding-left: 22px;
}

@media (max-width: 768px) {
    .revised-figure {
        width: 100%;
    }

    .revised-note {
        position: static;
        width: auto;
        transform: none;
        align-items: flex-start;
        text-align: left;
        margin-top: 0.75rem;
        padding-left: 1rem;
        border-left: 2px solid #7387B7;
    }

    .revised-arrow {
        display: none;
    }
}

.design-page .design-wide-img {
    margin: 0;
}

.designs-group {
    margin-bottom: 3.5rem;
}

.designs-group:last-child {
    margin-bottom: 0;
}

/* Character / Keyframe grids (Lost Stop) */
.character-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem 2rem;
    margin: 2rem 0;
}

.character-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
    margin-bottom: 1rem;
}

.character-name {
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.character-age {
    font-weight: 400;
    color: #999;
}

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

.keyframe-item {
    margin: 0;
}

.keyframe-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
    margin-bottom: 0.5rem;
}

.keyframe-grid-featured {
    grid-template-columns: 2.2fr 1fr;
    align-items: start;
}

/* Masonry-style gallery (Figure Drawings): images pack tightly with no
   uneven row gaps, since each column flows independently by height. */
.figure-gallery {
    column-count: 2;
    column-gap: 2rem;
    margin: 2rem 0;
}

.figure-item {
    break-inside: avoid;
    margin-bottom: 2rem;
}

.figure-item img,
.figure-item video {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 16px;
}

.problem-image-row {
    display: flex;
    gap: 2rem;
    margin: 4rem 0;
}

.problem-image {
    flex: 1;
    text-align: center;
}

.problem-image-frame {
    position: relative;
}

.problem-image img {
    display: block;
    width: 100%;
    height: 260px;
    object-fit: cover;
    border-radius: 12px;
}

.problem-image-heading {
    position: absolute;
    top: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    white-space: nowrap;
    font-size: 0.75rem;
    letter-spacing: 0.15rem;
    color: #1a1a1a;
    text-transform: uppercase;
}

/* Work Listing Page */
.work-listing {
    margin: 3rem 0 6rem;
}

.work-listing-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 4rem 4rem;
}

.work-listing-card {
    display: block;
    text-decoration: none;
    color: inherit;
}

.work-listing-card-media {
    position: relative;
    margin-bottom: 1.5rem;
}

.work-listing-card-thumb {
    width: 100%;
    aspect-ratio: 4 / 3;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.work-listing-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.work-listing-card-img-contain {
    object-fit: contain;
}

.work-listing-card:hover .work-listing-card-thumb {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
}

.work-listing-card-pin {
    position: absolute;
    top: -42px;
    right: -4%;
    width: 60px;
    height: auto;
    opacity: 0;
    transform: scale(0.6) rotate(-28deg);
    rotate: 28deg;
    pointer-events: none;
    z-index: 5;
}

.work-listing-card:hover .work-listing-card-pin {
    opacity: 1;
    transform: scale(1) rotate(-8deg);
}

.work-listing-card-title {
    font-size: 1.1rem;
    letter-spacing: 0.15rem;
    text-transform: uppercase;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.work-listing-card-meta {
    font-size: 0.7rem;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    color: #999;
    margin-bottom: 0.75rem;
}

.work-listing-card-desc {
    font-size: 0.85rem;
    letter-spacing: 0.03rem;
    color: #666;
    line-height: 1.6;
}

.work-listing-card-placeholder {
    cursor: default;
}

.work-listing-card-thumb-empty {
    background-color: #efefef;
    box-shadow: none;
}

.work-listing-card-placeholder .work-listing-card-title {
    color: #999;
}

.work-listing-card-meta-soon {
    color: #7387B7;
    font-weight: 600;
}

/* Mini Explorations */
.mini-explorations {
    margin: 2rem 0 6rem;
}

.mini-explorations-placeholder {
    width: 100%;
    min-height: 360px;
    background-color: #d9d9d9;
    border: 1px solid #ccc;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.placeholder-text {
    font-size: 0.75rem;
    letter-spacing: 0.12rem;
    text-transform: uppercase;
    color: #888;
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        flex-direction: column;
        padding: 2rem 1.5rem;
    }

    .me-columns {
        flex-direction: column;
    }

    .me-photo-frame {
        width: 100%;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-illustration {
        height: 300px;
    }

    .work-grid {
        height: auto;
        display: flex;
        flex-direction: column;
        gap: 3rem;
        max-width: 100%;
    }

    .work-item {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        max-width: 260px;
        margin: 0 auto;
    }

    .work-listing-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .design-flow-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .chart-grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }

    .chart-grid-2 {
        grid-template-columns: 1fr;
    }

    .feedback-row {
        flex-direction: column;
    }

    .design-pages-grid {
        grid-template-columns: 1fr;
    }

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

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

    .ps-header,
    .ps-pair {
        grid-template-columns: 1fr;
        gap: 0.5rem;
        text-align: center;
    }

    .ps-arrow {
        transform: rotate(90deg);
    }

    .figure-gallery {
        column-count: 1;
    }

    .nav-menu {
        gap: 1rem;
        font-size: 0.7rem;
    }

    .footer-links {
        justify-content: center;
        gap: 1.5rem;
    }
}

/* Landing page on phones: the hero stacks vertically, the draggable
   drawing hand is turned off, and the scattered work cards become a
   single column, so nothing is wider than the screen. */
@media (max-width: 768px) {
    body {
        overflow-x: clip;
    }

    .navbar {
        padding: 1.5rem;
    }

    .hero {
        display: flex;
        flex-direction: column;
        min-height: 0;
        padding: 1.5rem 1.5rem 2rem;
    }

    /* Letter-spacing also adds space after the last letter, so matching
       left padding keeps the centered text visually centered. */
    .hero-content {
        text-align: center;
    }

    .hero-title {
        font-size: 9vw;
        letter-spacing: 0.3em;
        padding-left: 0.3em;
    }

    .hero-subtitle {
        font-size: 4vw;
        letter-spacing: 0.2em;
        padding-left: 0.2em;
        margin-top: 0.5rem;
        margin-bottom: 1rem;
    }

    /* Pulled up so the name and tagline sit over the top of the gibbon */
    .hero-illustration {
        position: static;
        width: 100%;
        height: auto;
        margin-top: -5rem;
        text-align: center;
    }

    .gibbon {
        width: 85%;
        height: auto;
    }

    .hero-quote {
        order: 1;
        position: static;
        margin-top: 1.5rem;
        font-size: 12px;
    }

    .ink-drag-layer {
        display: none;
    }

    .featured-work {
        margin: 2rem auto 0;
        padding: 3rem 1.5rem;
    }

    .featured-divider {
        margin-top: -2rem;
    }

    .featured-star {
        top: 22rem;
        right: 0;
        width: 140px;
    }

    .work-grid {
        width: auto;
        margin: 3rem auto 0;
    }

    .work-item {
        height: 340px;
    }

    .footer {
        padding: 2rem 1.5rem;
        margin-top: 2rem;
    }
}


/* Sitewide box and table style, matching the Brilliance Exposed research
   tables: white with no outline, headings as bold body text in a darker
   block, hairline dividers, and all text at the 0.85rem body size. */
.feedback-box {
    max-width: 100%;
}

.feedback-box,
.features-box {
    padding: 0;
    overflow: hidden;
    overflow-wrap: break-word;
}

.feedback-box > .research-subtitle,
.features-box > .research-subtitle {
    display: block;
    margin: 0;
    padding: 1rem 2rem;
    background-color: #e6e4df;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
    text-transform: uppercase;
    text-align: left;
    color: #1a1a1a;
}

.feedback-box > .content-list,
.features-box > .content-list {
    margin: 0;
    padding: 1.25rem 2rem 1.5rem;
}

.stats-table-wrapper,
.results-table-wrapper {
    border: none;
    border-radius: 8px;
    background-color: #fff;
}

.rubric-table {
    border-radius: 8px;
    overflow: hidden;
}

.stats-table,
.results-table {
    background-color: #fff;
    font-size: 0.85rem;
    letter-spacing: 0.03rem;
}

.stats-table th,
.stats-table td,
.results-table th,
.results-table td {
    border: none;
    border-bottom: 1px solid #e0ded9;
    padding: 0.75rem 1rem;
}

.stats-table th + th,
.stats-table td + td,
.results-table th + th,
.results-table td + td {
    border-left: 1px solid #e0ded9;
}

.stats-table tbody tr:last-child td,
.results-table tbody tr:last-child td {
    border-bottom: none;
}

.stats-table thead th,
.results-table th {
    background-color: #dcd9d3;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.1rem;
    text-transform: uppercase;
    color: #666;
}

/* Row labels in the rubric read like the topic column on Brilliance Exposed */
.rubric-table td:first-child {
    background-color: #e6e4df;
}

/* Conclusions: short bulleted lists under bold subheadings */
.conclusion-section .problem-heading-body {
    margin-top: 2rem;
}

.conclusion-list {
    margin: 0.75rem 0 0;
    padding-left: 1.25rem;
}

/* Bold heading blocks all read as caps, matching the bold body headings
   like "USABILITY AND ARTISTIC EXPRESSION…" */
.analysis-head .research-subtitle,
.research-sources .research-subtitle,
.design-group-title {
    text-transform: uppercase;
}
