/* case-study-gapgpt.css - styles unique to case-study-gapgpt.html. Loaded after base.css. */

img { display: block; max-width: 100%;
}

/* ---------- Header ---------- */

header {
    padding: 32px 0;
    border-bottom: 1px solid var(--border);
}

header .wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-name {
    font-family: 'Newsreader', serif;
    font-size: 20px;
    font-weight: 500;
}

nav { display: flex; gap: 36px;
}

nav a {
    font-size: 14px;
    color: var(--text-secondary);
    position: relative;
    padding-bottom: 4px;
    transition: color 0.2s ease;
}

nav a:hover { color: var(--text-primary);
}

/* ---------- Section rhythm ---------- */

section { padding: 96px 0;
}

section.band { background: var(--surface);
}

section.tight { padding: 64px 0;
}

.eyebrow {
    width: 24px;
    height: 2px;
    background: var(--accent);
    margin-bottom: 20px;
}

h2 {
    font-family: 'Newsreader', serif;
    font-weight: 400;
    font-size: 30px;
    line-height: 1.3;
}

/* Explanatory caption under a section heading or gallery. */
.cs-caption {
    color: var(--text-secondary);
    font-size: 14px;
    margin-top: 16px;
    max-width: 640px;
}

/* ---------- Case study hero ----------
     GapGPT's hero is a single full-bleed illustration (the mascot artwork)
     rather than the phone-mockup grid used on the retail case studies -
     same card treatment, just one wide banner image. */

.cs-hero-art {
    display: block;
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    margin-bottom: 64px;
}

.cs-title .client {
    font-size: 14px;
    color: var(--accent);
    margin-bottom: 12px;
    letter-spacing: 0.02em;
}

.cs-title h1 {
    font-family: 'Newsreader', serif;
    font-weight: 400;
    font-size: 44px;
    line-height: 1.2;
    max-width: 780px;
}

/* ---------- Intro cards ---------- */

.intro-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-top: 56px;
}

.intro-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 28px;
}

.intro-card .icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.intro-card .icon.negative {
    background: var(--negative-soft);
    color: var(--negative);
}

.icon-svg {
    width: var(--icon-inline);
    height: var(--icon-inline);
}

.icon-svg-lg {
    width: var(--icon-feature);
    height: var(--icon-feature);
    margin-bottom: 28px;
    color: var(--accent);
}

.intro-card h3 {
    font-size: 17px;
    font-weight: 500;
    margin-bottom: 10px;
}

.intro-card p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ---------- Impact grid ---------- */

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

.impact-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 28px 24px;
    text-align: center;
    min-height: 210px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.impact-card p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Project-scope card: two stacked stat pairs instead of an icon. */

.impact-card.scope {
    gap: 18px;
}

.impact-card.scope .scope-item + .scope-item {
    margin-top: 18px;
}

.impact-card.scope .scope-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.impact-card.scope .scope-value {
    font-family: 'Newsreader', serif;
    font-size: 24px;
    color: var(--text-primary);
}

/* ---------- Goals (standalone numbered list, no image) ---------- */

.goals-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 48px;
}

.goal-item {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
}

.goal-item .solution-number {
    border-color: var(--accent-deep);
}

.goal-item h3 {
    font-size: 15px;
    font-weight: 500;
    margin-bottom: 4px;
}

.goal-item p {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ---------- Screenshots ----------
     Plain bordered treatment for product screenshots, sized to each
     image's own natural ratio so nothing is cropped or letterboxed. */

.solution-shot {
    display: block;
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 20px;
}

/* ---------- Image placeholders ----------
     Drop-in stand-ins for screenshots that haven't been added yet.
     Combine with a sizing class (.solution-shot, .gallery-shot,
     .cs-hero-art) so the layout doesn't shift once real images land -
     just swap the <div class="... img-placeholder"> for an <img>. */

.img-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
    padding: 20px;
    font-size: 13px;
    color: var(--text-muted);
    background: var(--bg);
    border: 1px dashed var(--border) !important;
    line-height: 1.5;
}

.img-placeholder .ph-note {
    font-size: 11px;
    font-style: italic;
    color: var(--text-muted);
    opacity: 0.7;
}

/* ---------- Solution: numbered screenshots ---------- */

.solution-item {
    margin-top: 56px;
}

.solution-item:first-of-type {
    margin-top: 48px;
}

.solution-caption-group {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.solution-caption {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    max-width: 640px;
}

.solution-number {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 50%;
    border: 1px solid var(--accent-deep);
    color: var(--accent);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.solution-caption p {
    font-size: 14px;
    color: var(--text-secondary);
    padding-top: 5px;
}

/* ---------- Image galleries (feature scoping / explorations) ---------- */

.gallery { margin-top: 48px; display: flex; flex-direction: column; gap: 20px;
}

.gallery-figure { margin: 0;
}

.gallery-caption {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 12px;
}

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

.gallery-grid.two-up {
    grid-template-columns: 1fr 1fr;
}

.gallery-shot {
    display: block;
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    cursor: zoom-in;
}

.gallery-grid .gallery-caption {
    font-size: 13px;
    margin-top: 10px;
}

/* ---------- Lightbox ---------- */

.lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    background: rgba(10,10,10,0.94);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    cursor: zoom-out;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease;
}

.lightbox-overlay.is-open { opacity: 1; visibility: visible;
}

.lightbox-overlay img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 24px 80px rgba(0,0,0,0.6);
}

.lightbox-close {
    position: absolute;
    top: 28px;
    right: 32px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-primary);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ---------- Final words ---------- */

.final-words p {
    font-size: 17px;
    color: var(--text-secondary);
    max-width: 700px;
    margin-top: 24px;
}

.back-to-top {
    display: inline-block;
    margin-top: 40px;
    font-size: 14px;
    color: var(--accent);
    border-bottom: 1px solid var(--accent-deep);
    padding-bottom: 2px;
}

/* ---------- More projects ---------- */

.more-projects-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    max-width: 640px;
    margin-top: 32px;
}

.more-projects-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
    max-width: 960px;
}

.more-project-thumb {
    width: 100%;
    aspect-ratio: 16 / 10;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 14px;
    transition: border-color 0.2s ease;
}

.more-project-card:hover .more-project-thumb {
    border-color: var(--accent-deep);
}

.more-project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.more-project-card:hover .more-project-thumb img {
    transform: scale(1.03);
}

.more-project-client {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
    letter-spacing: 0.02em;
}

.more-project-title {
    font-size: 15px;
    font-weight: 500;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.more-project-title .arrow {
    color: var(--accent);
    width: 14px;
    height: 14px;
    margin-top: 5px;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.more-project-card:hover .more-project-title .arrow {
    transform: translateX(4px);
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
    .wrap { padding: 0 24px; }
    .cs-hero-art { margin-bottom: 40px; }
    .cs-title h1 { font-size: 32px; }
    .intro-grid { grid-template-columns: 1fr; }
    .impact-grid { grid-template-columns: 1fr; gap: 12px; }
    .goals-list { grid-template-columns: 1fr; }
    .gallery-grid, .gallery-grid.two-up { grid-template-columns: 1fr; }
    .more-projects-grid, .more-projects-grid.cols-3 { grid-template-columns: 1fr 1fr; gap: 16px; max-width: 100%; }
    section { padding: 64px 0; }
    .lightbox-overlay { padding: 24px; }
}

/* ---------- Motion: hover lift for cards ---------- */

.intro-card, .impact-card, .goal-item {
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.intro-card:hover, .impact-card:hover, .goal-item:hover {
    transform: translateY(-2px);
    border-color: var(--accent-deep);
    box-shadow: 0 8px 18px rgba(0,0,0,0.3);
}

/* ---------- Motion: image hover scale ---------- */

.cs-hero-art, .solution-shot, .gallery-shot {
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.cs-hero-art:hover, .solution-shot:hover, .gallery-shot:hover {
    transform: scale(1.01);
}

@media (prefers-reduced-motion: reduce) {
    body { opacity: 1; transition: none; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .intro-card, .impact-card, .goal-item,
    .cs-hero-art, .solution-shot, .gallery-shot,
    .more-project-thumb img, .lightbox-overlay {
      transition: none;
    }
    .intro-card:hover, .impact-card:hover, .goal-item:hover {
      transform: none;
    }
    .cs-hero-art:hover, .solution-shot:hover, .gallery-shot:hover,
    .more-project-card:hover .more-project-thumb img {
      transform: none;
    }
}

/* ---------- Theme toggle ---------- */

.header-actions {
    display: flex;
    align-items: center;
    gap: 36px; /* matches nav's gap, so Contact-to-toggle spacing matches Contact-to-Resume */
}

/* ---------- Mobile nav ---------- */

.hamburger-btn {
    display: none;
    background: transparent;
    border: none;
    padding: 6px;
    cursor: pointer;
    color: var(--text-primary);
    position: relative;
    z-index: 60;
}
