/* INDEX / HOMEPAGE MOBILE PATCH */
@media (max-width: 767px) {
    main[data-aos="fade-in"] {
        min-height: auto;
        padding: 1rem 1rem 2rem;
    }

    .bg-grid {
        background-size: 16px 16px;
    }

    h1 {
        word-break: break-word;
    }

    .hard-shadow,
    .hard-shadow-fuchsia,
    .hard-shadow-lime,
    .hard-shadow-cyan,
    .hard-shadow-red,
    .hard-shadow-yellow {
        box-shadow: 3px 3px 0px #000;
    }

    .hard-shadow:hover {
        box-shadow: 3px 3px 0px #000;
        transform: none;
    }

    .btn-push:hover,
    .btn-push:active {
        transform: none;
        box-shadow: 3px 3px 0px #000;
    }

    .hazard-stripes span {
        font-size: 0.85rem !important;
        line-height: 1.3;
        display: inline-block;
        padding: 0.25rem 0.5rem;
    }

    .glitch-wrapper {
        display: inline-block;
        max-width: 100%;
    }

    .glitch {
        display: inline-block;
        max-width: 100%;
        word-break: break-word;
    }

    .glitch::before,
    .glitch::after {
        display: none;
    }

    .nav-contact-wrap {
        display: none;
    }

    .text-6xl {
        font-size: 3rem !important;
        line-height: 0.95 !important;
    }

    .md\:text-\[7rem\] {
        font-size: 3.4rem !important;
    }

    .w-48.h-48 {
        width: 9rem !important;
        height: 9rem !important;
    }

    .max-w-\[76rem\] {
        max-width: 100% !important;
    }

    .text-\[1\.9rem\] {
        font-size: 1.55rem !important;
        line-height: 1.05 !important;
    }

    .text-base.md\:text-xl {
        font-size: 0.98rem !important;
        line-height: 1.55 !important;
    }

    .text-\[0\.62rem\] {
        font-size: 0.68rem !important;
        line-height: 1.35 !important;
    }

    .w-full.flex.justify-center.mt-6.md\:mt-12 > div {
        padding: 1.25rem 1rem !important;
    }

    .flex.flex-wrap.justify-center.gap-3.md\:gap-4.mb-5 span {
        font-size: 0.78rem !important;
        padding: 0.6rem 0.8rem !important;
    }

    section.p-4.py-12,
    section.p-4.py-16,
    section.p-4.py-20,
    section.bg-yellow-300,
    section#writing,
    section#video,
    section#builder {
        padding-top: 3.5rem !important;
        padding-bottom: 3.5rem !important;
    }

    .grid.grid-cols-2.md\:grid-cols-4.gap-4 {
        gap: 0.75rem !important;
    }

    .grid.grid-cols-2.md\:grid-cols-4.gap-4 > div {
        padding: 0.85rem 0.6rem !important;
    }

    .grid.grid-cols-2.md\:grid-cols-4.gap-4 > div span:first-child {
        font-size: 1.6rem !important;
        line-height: 1 !important;
    }

    .grid.grid-cols-2.md\:grid-cols-4.gap-4 > div span:last-child {
        font-size: 0.68rem !important;
        line-height: 1.25 !important;
    }

    .featured-case-study-mobile,
    .featured-case-study-mobile * {
        word-break: normal;
    }

    .featured-case-study-mobile h2 {
        font-size: 2.5rem !important;
        line-height: 0.95 !important;
    }

    .featured-case-study-mobile .preview-subhead {
        font-size: 1.35rem !important;
        line-height: 1.15 !important;
    }

    .featured-case-study-mobile .preview-body {
        font-size: 1rem !important;
        line-height: 1.6 !important;
    }

    .featured-case-study-mobile .preview-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }

    .featured-case-study-mobile .preview-cta-row {
        display: flex !important;
        flex-direction: column !important;
        gap: 0.75rem !important;
    }

    .featured-case-study-mobile .preview-cta-row > * {
        width: 100% !important;
        justify-content: center !important;
        text-align: center !important;
    }

    .featured-case-study-mobile .preview-panel {
        padding: 1.25rem !important;
    }

    .featured-case-study-mobile .preview-panel li {
        font-size: 1rem !important;
        line-height: 1.45 !important;
    }

    #social-header,
    #writing-header,
    #video-header,
    #builder-header {
        font-size: 2.4rem !important;
        line-height: 0.95 !important;
        padding-left: 1rem !important;
        margin-bottom: 1rem !important;
    }

    #social-grid,
    #writing-grid,
    #video-grid,
    #builder-grid {
        gap: 1rem !important;
    }

    .skeleton {
        min-height: 220px !important;
    }

    .video-card h3,
    .builder-card h3 {
        font-size: 1.2rem !important;
        line-height: 1.15 !important;
    }

    footer .contact-form {
        padding: 1.25rem !important;
    }

    footer h2.text-5xl,
    footer h2.md\:text-8xl {
        font-size: 2.35rem !important;
        line-height: 0.95 !important;
    }

    footer .text-lg.md\:text-2xl {
        font-size: 1rem !important;
        line-height: 1.5 !important;
    }

    footer .w-full.px-6.py-4.text-lg.md\:text-2xl {
        font-size: 1rem !important;
        line-height: 1.2 !important;
        padding: 1rem !important;
    }

    footer .flex.gap-4 {
        gap: 0.5rem !important;
    }

    footer .w-12.h-12 {
        width: 2.75rem !important;
        height: 2.75rem !important;
    }
}

/* WRITING / MEDIUM CTA LAYOUT */
#writing > .max-w-7xl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 1.5rem;
}

#writing-header,
#writing > .max-w-7xl > p,
#writing-filters {
    grid-column: 1 / -1;
}

#writing-grid {
    display: contents;
}

#writing-grid .writing-item {
    margin-bottom: 1.5rem;
}

#writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) {
    grid-column: 1 / -1;
    justify-self: center;
    align-self: start;
    width: max-content;
    max-width: 100%;
    min-height: 0;
    margin-top: 1.5rem;
    margin-bottom: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

#writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) > div {
    display: none;
}

#writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) > a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    border: 2px solid #000;
    background: #bef264;
    color: #000 !important;
    box-shadow: 4px 4px 0 #000;
    font-size: 0;
    line-height: 1;
    text-decoration: none !important;
    transition: transform 0.2s ease-out, box-shadow 0.2s ease-out, background-color 0.2s ease-out;
}

#writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) > a::before {
    content: "Read More on Medium ↗";
    font-size: 1.25rem;
    font-weight: 900;
    text-transform: uppercase;
}

#writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) > a:hover {
    background: #67e8f9;
    transform: translate(-1px, -1px);
    box-shadow: 6px 6px 0 #000;
}

#writing > .max-w-7xl > div:has(#writing-toggle-btn) {
    align-self: start;
    margin-top: 1.5rem !important;
}

/* On All, pair the two CTAs as one centered row: Show All | Medium. */
#writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) > div:has(#writing-toggle-btn) {
    grid-column: 1;
    justify-self: end;
    text-align: right;
    order: 1000;
}

#writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) {
    grid-column: 2;
    justify-self: start;
    order: 1001;
}

@media (max-width: 767px) {
    #writing > .max-w-7xl {
        grid-template-columns: 1fr;
        column-gap: 0;
    }

    #writing-header,
    #writing > .max-w-7xl > p,
    #writing-filters,
    #writing-grid .writing-item,
    #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]),
    #writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]),
    #writing > .max-w-7xl > div:has(#writing-toggle-btn),
    #writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) > div:has(#writing-toggle-btn) {
        grid-column: 1;
    }

    #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]),
    #writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]),
    #writing > .max-w-7xl > div:has(#writing-toggle-btn),
    #writing > .max-w-7xl:has(#writing-toggle-btn[style*="inline-block"]) > div:has(#writing-toggle-btn) {
        justify-self: stretch;
        text-align: center;
    }

    #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) {
        width: 100%;
    }

    #writing-grid .writing-item.medium:has(> a[href="https://medium.com/@hirebencampbell"]) > a,
    #writing-toggle-btn {
        width: 100%;
    }
}
