/* ============================================
   CASE STUDY — Card grid, Teaser, Detail Page,
   Full-width Hero
   Loaded ONLY on Case Study pages
   ============================================ */

/* Case Studies Teaser (Menzel-style cards) */
.case-teaser-section {
    background-color: #f8f9fa;
    padding: 40px 0;
}

.case-teaser-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 36px;
    font-weight: 700;
    text-transform: uppercase;
    color: #1a2035;
    margin-bottom: 30px;
    text-align: center;
}

.case-teaser-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.case-teaser-card {
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.3s ease;
    border-radius: 4px;
    overflow: hidden;
}

.case-teaser-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.case-teaser-card-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    background: #1a2035;
    display: flex;
    align-items: center;
    justify-content: center;
}

.case-teaser-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.case-teaser-card-body {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.case-teaser-card-body h3 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 22px;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 20px;
    color: #1a2035;
    text-transform: uppercase;
}

.case-teaser-specs {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 15px;
    color: #4a5568;
    line-height: 1.8;
    margin-bottom: 25px;
    flex-grow: 1;
}

.case-teaser-link {
    font-family: 'Share Tech Mono', monospace;
    font-size: 14px;
    color: #ff6b00;
    text-decoration: none;
    text-transform: lowercase;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.2s ease;
}

.case-teaser-link:hover {
    gap: 12px;
}

.case-teaser-motor-bg {
    font-family: 'Rajdhani', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.1);
    text-transform: uppercase;
    text-align: center;
}

.case-teaser-view-all {
    text-align: center;
    margin-top: 50px;
}

.view-all-btn {
    display: inline-block;
    background-color: #ff6b00;
    color: #ffffff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 16px 40px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.view-all-btn:hover {
    background-color: #1a2035;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.case-studies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
    margin-top: 48px;
}

/* Case Study Teaser Card */
.case-study-teaser {
    background: #ffffff;
    border: 1px solid #dce3ed;
    border-top: 3px solid #ff6b00;
    padding: 32px 28px;
    transition: all 0.3s;
}

.case-study-teaser:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border-color: #ff6b00;
}

.case-teaser-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.case-industry,
.case-motor {
    font-family: 'Share Tech Mono', monospace;
    font-size: 10px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 2px;
}

.case-industry {
    background: #e8eef6;
    color: #1a2035;
}

.case-motor {
    background: rgba(255, 107, 0, 0.1);
    color: #ff6b00;
    border: 1px solid rgba(255, 107, 0, 0.3);
}

.case-study-teaser h3 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 22px;
    color: #1a2035;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.case-client {
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    color: #ff6b00;
    letter-spacing: 0.08em;
    margin-bottom: 16px;
}

.case-results-preview {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.7;
    font-weight: 300;
}

/* Full Case Study Cards List */
.case-studies-list {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 48px;
}

.case-study-card {
    background: #ffffff;
    border: 1px solid #dce3ed;
    border-left: 4px solid #ff6b00;
    overflow: hidden;
}

.case-study-header {
    background: #1a2035;
    padding: 32px 36px;
}

.case-study-header .case-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
}

.case-study-header .case-title {
    font-family: 'Rajdhani', sans-serif;
    font-size: 28px;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.case-study-header .case-client {
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.1em;
}

.case-study-body {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 0;
}

.case-section {
    padding: 28px 32px;
    border-right: 1px solid #dce3ed;
}

.case-section:last-child {
    border-right: none;
}

.case-section h4 {
    font-family: 'Share Tech Mono', monospace;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #ff6b00;
    margin-bottom: 12px;
}

.case-section p {
    color: #4a5568;
    font-size: 15px;
    line-height: 1.7;
    font-weight: 300;
}

.case-results {
    background: #f8fafb;
}

.case-results p {
    color: #1a2035;
    font-weight: 600;
}

/* Case Studies Page Filter + Card Grid */
.case-studies-page {
    padding: 48px 0;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
}

.case-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 40px;
}

.filter-btn {
    padding: 8px 20px;
    background: transparent;
    border: 1px solid #dce3ed;
    color: #4a5568;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 2px;
}

.filter-btn:hover,
.filter-btn.active {
    background: #1a2035;
    color: #ffffff;
    border-color: #1a2035;
}

/* Case Card */
.case-card {
    background: #ffffff;
    border: 1px solid #dce3ed;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.case-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
    border-color: #ff6b00;
}

.case-card-image {
    background: #1a2035;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.case-motor-bg,
.case-detail-motor-bg {
    font-family: 'Rajdhani', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.15);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-align: center;
    padding: 20px;
}

.case-card-body {
    padding: 28px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.case-card-tags {
    display: flex;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.tag-industry {
    font-family: 'Share Tech Mono', monospace;
    font-size: 20px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    padding: 4px 10px;
    background: #e8eef6;
    color: #1a2035;
    border-radius: 2px;
}

.tag-motor {
    font-family: 'Share Tech Mono', monospace;
    font-size: 20px;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    padding: 4px 10px;
    background: rgba(255, 107, 0, 0.1);
    color: #ff6b00;
    border: 1px solid rgba(255, 107, 0, 0.3);
    border-radius: 2px;
}

.case-card h3 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 20px;
    color: #1a2035;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.case-card-client {
    font-family: 'Share Tech Mono', monospace;
    font-size: 11px;
    color: #9aa0ad;
    letter-spacing: 0.08em;
    margin-bottom: 20px;
}

.read-more-link {
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #ff6b00;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    transition: color 0.2s;
    margin-top: auto;
}

.read-more-link:hover {
    color: #cc5500;
}

/* Case Detail Hero */
.case-detail-hero {
    position: relative;
    background: #0a0a0a;
    min-height: 380px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.case-detail-hero-bg {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.case-detail-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.case-detail-motor-bg {
    font-size: 120px;
    color: rgba(255, 255, 255, 0.04);
    letter-spacing: 0.05em;
}

.case-detail-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 107, 0, 0.08) 0%, transparent 60%);
}

.case-detail-hero-content {
    position: relative;
    z-index: 2;
    padding: 80px 24px;
}

.case-detail-tags {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.case-detail-hero-content h1 {
    font-family: 'Rajdhani', sans-serif;
    font-size: clamp(32px, 5vw, 56px);
    color: rgb(224, 149, 10);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 12px;
}

.case-detail-client {
    font-family: 'Share Tech Mono', monospace;
    font-size: 20px;
    color: rgb(224, 149, 10);
    letter-spacing: 0.1em;
}

/* Detail Body */
.case-detail-body {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 64px;
    padding: 72px 24px;
}

.case-detail-main {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.case-detail-section h2 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 28px;
    color: #1a2035;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f0f4f8;
}

.section-num {
    font-family: 'Share Tech Mono', monospace;
    font-size: 13px;
    color: #ff6b00;
    letter-spacing: 0.15em;
}

.case-detail-section p {
    color: #4a5568;
    font-size: 16px;
    line-height: 1.8;
    font-weight: 300;
}

.case-results-section {
    background: #f0f4f8;
    padding: 32px;
    border-left: 4px solid #ff6b00;
}

.case-results-section p {
    color: #1a2035;
    font-weight: 600;
    font-size: 17px;
}

/* Detail Sidebar */
.case-detail-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sidebar-card {
    background: #f8fafb;
    border: 1px solid #dce3ed;
    border-top: 3px solid #ff6b00;
    padding: 28px;
}

.sidebar-card h4 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 16px;
    color: #1a2035;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #dce3ed;
}

.sidebar-item {
    padding: 10px 0;
    border-bottom: 1px solid #dce3ed;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-item:last-child {
    border-bottom: none;
}

.sidebar-label {
    font-family: 'Share Tech Mono', monospace;
    font-size: 10px;
    color: #ff6b00;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.sidebar-value {
    color: #1a2035;
    font-size: 15px;
    font-weight: 600;
}

.sidebar-cta {
    background: #1a2035;
    border-top-color: #ff6b00;
}

.sidebar-cta h4 {
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.sidebar-cta p {
    color: #9aa0ad;
    font-size: 14px;
    line-height: 1.7;
    font-weight: 300;
    margin-bottom: 20px;
}

/* Back Link */
.case-detail-back {
    padding: 24px;
}

.back-link {
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    color: #9aa0ad;
    letter-spacing: 0.1em;
    text-decoration: none;
    transition: color 0.2s;
}

.back-link:hover {
    color: #ff6b00;
}

/* CTA Section */
.case-cta-section {
    background: #1a2035;
    padding: 80px 0;
    text-align: center;
}

.case-cta-section h2 {
    font-family: 'Rajdhani', sans-serif;
    font-size: 42px;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 16px;
}

.case-cta-section p {
    color: #9aa0ad;
    font-size: 17px;
    font-weight: 300;
    margin-bottom: 32px;
}

/* Full-Width Hero Breakout */
.case-hero-fullwidth {
    position: relative;
    overflow: hidden;
    min-height: 600px;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    display: flex;
    align-items: center;
    color: white;
    text-align: center;
    background: #1a1a2e;
}

.case-hero-fullwidth .hero-video-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.case-hero-fullwidth .hero-video-wrapper video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
}

.case-hero-eyebrow {
    font-family: 'Share Tech Mono', monospace;
    font-size: 12px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #ff6b00;
    margin-bottom: 16px;
}

.case-hero-fullwidth h1 {
    font-size: clamp(40px, 6vw, 72px);
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 20px;
}

.case-hero-sub {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.65);
    font-weight: 300;
    max-width: 560px;
    margin: 0 auto;
}

/* Hide default page header on case study page */
body.page-case-study .page-header {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .case-study-body {
        grid-template-columns: 1fr;
    }

    .case-section {
        border-right: none;
        border-bottom: 1px solid #dce3ed;
    }

    .case-detail-body {
        grid-template-columns: 1fr;
    }

    .case-detail-motor-bg {
        font-size: 60px;
    }
}