/* ONYX CASE STUDY STYLES */

/* Font */
@font-face {
    font-family: "HelveticaNowDisplay";
    src: url("/assets/HelveticaNowDisplay-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
}

/* Force light mode - override darkmode variables */
html.darkmode .case-page,
.case-page {
    --color-content-primary: #000000;
    --color-surface-primary: #F0E5D5;
    --color-accent: #AA0000;
    --color-hero-bg: #0f0a0a;
    --color-hero-text: #FFFFFF;
    --color-divider: rgba(0, 0, 0, 0.12);
}

/* Page Container */
.case-page {
    background: var(--color-surface-primary);
    color: var(--color-content-primary);
    min-height: 100vh;
}

/* Hero Section */
.case-hero {
    background: var(--color-hero-bg);
    color: var(--color-hero-text);
    padding: 3rem 4rem 4rem;
    position: relative;
}

.case-hero-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 4rem;
}

.case-hero .logo-link {
    display: block;
    width: 100px;
    transition: opacity 0.2s ease;
}

.case-hero .logo-link:hover {
    opacity: 0.7;
    animation: none;
}

.case-hero .logo-link svg {
    width: 100%;
    height: auto;
}

.case-hero .logo-link svg path {
    fill: #ff0000;
}

.case-hero-content {
    max-width: 800px;
}

.case-hero h1 {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 5rem;
    font-weight: 400;
    line-height: 1;
    letter-spacing: -0.03em;
    margin: 0 0 1rem 0;
    padding: 0;
    visibility: visible;
    width: auto;
    height: auto;
    color: #ff0000;
    text-indent: 0;
}

.case-hero .hero-subtitle {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 1.65rem;
    font-weight: 300;
    line-height: 1.4;
    opacity: 0.85;
    margin: 0;
    padding: 0;
    max-width: 600px;
}

/* Hero Image */
.case-hero-image {
    width: 100%;
    max-width: 594px;
    margin: -4rem auto 2rem;
    padding: 0;
    position: relative;
    z-index: 2;
}

.case-hero-image img {
    width: 100%;
    height: auto;
    max-height: 400px;
    display: block;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Placeholder for missing image */
.case-hero-image-placeholder {
    width: 100%;
    max-width: 594px;
    margin: -4rem auto 3rem;
    padding: 0;
    position: relative;
    z-index: 2;
}

.case-hero-image-placeholder .placeholder-box {
    width: 100%;
    aspect-ratio: 1128 / 412;
    background: linear-gradient(135deg, #e8e4e0 0%, #d4cfc9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.case-hero-image-placeholder .placeholder-text {
    font-family: "GT Alpina Typewriter", Courier, monospace;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    opacity: 0.4;
    color: var(--color-content-primary);
}

/* Main Content */
.case-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 4rem 4rem;
}

/* Two Column Section */
.case-section-two-col {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 4rem;
    padding: 3rem 0;
    border-bottom: 1px solid var(--color-divider);
}

.case-section-two-col:first-of-type {
    border-top: none;
}

/* Left Column - Label */
.section-left {
    padding-top: 0.25rem;
}

.section-label {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1rem;
    opacity: 0.5;
    display: block;
    margin-bottom: 0.75rem;
}

.section-link {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1rem;
    color: var(--color-accent);
    text-decoration: none;
    transition: opacity 0.15s ease;
}

.section-link:hover {
    opacity: 0.6;
    animation: none;
    cursor: crosshair;
}

/* Right Column - Content */
.section-right {
    /* Content area */
}

.section-right p {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.4rem;
    line-height: 1.4;
    margin: 0;
    padding: 0;
    text-wrap: wrap;
}

/* Deliverables List */
.deliverables-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.deliverables-list li {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.4rem;
    line-height: 1.4;
    padding: 0;
    padding-left: 1.25rem;
    position: relative;
}

.deliverables-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 5px;
    height: 5px;
    background: var(--color-content-primary);
    border-radius: 50%;
    opacity: 0.4;
}

/* Outcomes Section */
.outcomes-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
}

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

.outcome-number {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 4.5rem;
    font-weight: 300;
    line-height: 1;
    letter-spacing: -0.02em;
    color: var(--color-content-primary);
}

.outcome-label {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 1.1rem;
    line-height: 1.4;
    opacity: 0.7;
    max-width: 280px;
}

/* Takeaways Summary Section */
.takeaways-summary {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.takeaway-summary-item {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0;
    padding: 0;
    color: var(--color-content-primary);
    text-decoration: none;
    display: block;
    transition: color 0.2s ease;
}

.takeaway-summary-item:hover {
    color: #555555;
    cursor: crosshair;
}

/* Takeaway Detail Sections */
.takeaway-big-number {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 5rem;
    font-weight: 300;
    line-height: 1;
    letter-spacing: -0.02em;
    margin: 0;
    padding: 0;
}

.takeaway-subtitle {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.4;
    margin: 0.5rem 0 0 0;
    padding: 0;
    opacity: 1;
}

.takeaway-detail-title {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 1rem 0;
    padding: 0;
}

.takeaway-detail-text {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.4rem;
    line-height: 1.4;
    opacity: 0.7;
    margin: 0;
    padding: 0;
}

/* CTA Section */
.case-cta {
    padding: 4rem 0 2rem;
    text-align: center;
}

.cta-button {
    display: inline-block;
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1rem;
    padding: 1rem 2.5rem;
    border: 1px solid var(--color-content-primary);
    background: transparent;
    color: var(--color-content-primary);
    text-decoration: none;
    transition: all 0.15s ease;
    cursor: crosshair;
}

.cta-button:hover {
    background: var(--color-content-primary);
    color: var(--color-surface-primary);
    animation: none;
}

/* Footer */
.case-footer {
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid var(--color-divider);
}

.case-footer a {
    font-family: "GT Alpina Typewriter", Courier, monospace;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    color: inherit;
    text-decoration: none;
    opacity: 0.5;
    transition: opacity 0.15s ease;
}

.case-footer a:hover {
    opacity: 1;
    animation: none;
    cursor: crosshair;
}

/* Takeaway Content Tables & Lists */
.takeaway-content {
    margin-top: 1rem;
}

.takeaway-image {
    margin: 2rem 0;
    max-width: 100%;
}

.takeaway-image img {
    width: 100%;
    max-width: 600px;
    height: auto;
    display: block;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
    border-radius: 4px;
}

.takeaway-content p {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.4rem;
    line-height: 1.4;
    opacity: 0.7;
    margin: 0.75rem 0;
    padding: 0;
    text-wrap: wrap;
}

.takeaway-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.2rem;
}

.takeaway-content thead {
    border-bottom: 2px solid var(--color-divider);
}

.takeaway-content th {
    text-align: left;
    padding: 0.75rem 1rem 0.75rem 0;
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    font-weight: 500;
    opacity: 0.6;
}

.takeaway-content td {
    padding: 0.85rem 1rem 0.85rem 0;
    border-bottom: 1px solid var(--color-divider);
    opacity: 0.7;
    vertical-align: top;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.takeaway-content tbody tr:last-child td {
    border-bottom: none;
}

.takeaway-content h4 {
    font-family: "HelveticaNowDisplay", "Helvetica Neue", Arial, sans-serif;
    font-size: 1.2rem;
    font-weight: 400;
    margin: 1.5rem 0 0.5rem;
    opacity: 0.9;
}

.takeaway-content ul {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 1rem;
}

.takeaway-content li {
    font-family: "adobe-garamond-pro", "Garamond", "Times New Roman", serif;
    font-size: 1.2rem;
    line-height: 1.5;
    padding: 0.25rem 0 0.25rem 1.25rem;
    position: relative;
    opacity: 0.7;
}

.takeaway-content li::before {
    content: "•";
    position: absolute;
    left: 0;
    opacity: 0.5;
}

.takeaway-content .rule-box {
    background: rgba(0, 0, 0, 0.03);
    border-left: 2px solid var(--color-content-primary);
    padding: 1rem 1.25rem;
    margin: 1rem 0;
    font-family: "GT Alpina Typewriter", Courier, monospace;
    font-size: 1rem;
    line-height: 1.6;
    opacity: 0.8;
}

.takeaway-content .rule-box p {
    font-family: inherit;
    font-size: inherit;
    margin: 0.25rem 0;
}

.takeaway-content .trigger-item {
    margin: 0.75rem 0;
}

.takeaway-content .trigger-key {
    font-family: "GT Alpina Typewriter", Courier, monospace;
    font-size: 1.1rem;
    font-weight: 600;
    opacity: 0.9;
}

/* Mobile Responsive */
@media screen and (max-width: 900px) {
    .case-section-two-col {
        grid-template-columns: 150px 1fr;
        gap: 2rem;
    }

    .outcomes-grid {
        gap: 2rem;
    }

    .outcome-number {
        font-size: 3.5rem;
    }
}

@media screen and (max-width: 600px) {
    .case-hero {
        padding: 2rem 1.5rem 3rem;
    }

    .case-hero-header {
        margin-bottom: 2.5rem;
    }

    .case-hero .logo-link {
        width: 70px;
    }

    .case-hero h1 {
        font-size: 3.3rem;
    }

    .case-hero .hero-subtitle {
        font-size: 1.3rem;
    }

    .case-hero-image,
    .case-hero-image-placeholder {
        margin: -2rem auto 2rem;
        padding: 0 1.5rem;
    }

    .case-content {
        padding: 1rem 1.5rem 3rem;
    }

    .case-section-two-col {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 2rem 0;
    }

    .section-left {
        padding-top: 0;
    }

    .section-right p {
        font-size: 1.4rem;
    }

    .outcomes-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .outcome-number {
        font-size: 4rem;
    }

    .takeaway-summary-item {
        font-size: 1.4rem;
    }

    .takeaway-big-number {
        font-size: 4rem;
    }

    .takeaway-detail-title {
        font-size: 1.5rem;
    }

    .takeaway-detail-text {
        font-size: 1.4rem;
    }

    .takeaway-content table {
        font-size: 1rem;
        display: block;
        overflow-x: auto;
    }

    .takeaway-content thead,
    .takeaway-content tbody,
    .takeaway-content tr {
        display: table;
        width: 100%;
        table-layout: fixed;
    }

    .takeaway-content th,
    .takeaway-content td {
        font-size: 0.9rem;
        padding: 0.6rem 0.5rem 0.6rem 0;
        word-break: break-word;
        hyphens: auto;
    }

    .takeaway-content th:nth-child(1),
    .takeaway-content td:nth-child(1) {
        width: 20%;
    }

    .takeaway-content th:nth-child(2),
    .takeaway-content td:nth-child(2) {
        width: 35%;
    }

    .takeaway-content th:nth-child(3),
    .takeaway-content td:nth-child(3) {
        width: 45%;
    }

    .case-cta {
        padding: 3rem 0 1.5rem;
    }
}
