/* Maverick What We Do Block Styles */

.maverick-whatwedo-block {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.whatwedo-wrapper {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 60px;
    min-height: 450px;
}

/* Sideways Title */
.whatwedo-title-container {
    flex-shrink: 0;
    width: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 400px;
}

.whatwedo-title {
    font-size: 4rem;
    font-weight: 800;
    color: var(--primary);
    margin: 0;
    line-height: 1;
    writing-mode: sideways-lr;
    text-align: center;
}

/* Main Content Area */
.whatwedo-main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Cards Grid */
.whatwedo-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    width: 100%;
}

/* Individual Card */
.whatwedo-card {
    position: relative;
    width: 100%;
    height: 300px;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
    box-shadow: 0px 0px 32px #02304780;
}

.whatwedo-card:hover {
    transform: scale(1.02);
}

/* Card Content Container */
.card-content {
    position: relative;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--tertiary), var(--primary));
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Main Card State */
.card-main {
    position: absolute;
    bottom: 0;
    left: 0;
    z-index: 2;
    text-align: left;
    padding: 25px;
    width: 100%;
}

.card-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
    margin: 0;
    text-transform: uppercase;
    line-height: 1.2;
}

/* Card Overlay (Hover State) */
.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, var(--tertiary), var(--primary));
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 3;
}

.whatwedo-card:hover .card-overlay {
    opacity: 1;
    visibility: visible;
}

.overlay-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 25px;
    color: white;
}

.overlay-text {
    flex: 1;
}

.overlay-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin: 0 0 15px 0;
    text-transform: uppercase;
    line-height: 1.2;
}

.overlay-copy {
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.overlay-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: white;
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    margin-top: auto;
}

.overlay-link:hover {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transform: translateX(5px);
}

.overlay-link i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.overlay-link:hover i {
    transform: translateX(3px);
}

/* Block CTA */
.whatwedo-cta {
    display: flex;
    justify-content: flex-end;
    width: 100%;
}

.cta-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    padding: 10px 0;
}

.cta-link:hover {
    color: var(--secondary);
    text-decoration: none;
    transform: translateX(5px);
}

.cta-link i {
    font-size: 1.3rem;
    transition: transform 0.3s ease;
}

.cta-link:hover i {
    transform: translateX(5px);
}

/* Floating Animations */
@keyframes floatOdd {
    0%, 100% {
        transform: translateY(-40px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes floatEven {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

.whatwedo-card:nth-child(odd) {
    animation: floatOdd 6s ease-in-out infinite;
}

.whatwedo-card:nth-child(even) {
    animation: floatEven 6s ease-in-out infinite;
}

.whatwedo-card:hover {
    animation-play-state: paused;
}

@media (max-width: 1400px) {
    .card-title {
        font-size: 22px;
    }
}

/* Tablet Styles */
@media (max-width: 1199px) {
    .whatwedo-wrapper {
        gap: 40px;
    }

    .whatwedo-title-container {
        width: 150px;
        height: 350px;
    }

    .whatwedo-title {
        font-size: 3rem;
    }

    .whatwedo-cards-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 25px;
    }

    .whatwedo-card {
        height: 250px;
    }

    .card-title {
        font-size: 1.5rem;
    }

    .overlay-title {
        font-size: 1.3rem;
    }

    .overlay-copy {
        font-size: 0.9rem;
    }
}

@media (max-width: 991px) {
    .whatwedo-wrapper {
        flex-direction: column;
        gap: 40px;
        padding: 60px 0;
        text-align: center;
        align-items: center;
    }

    .whatwedo-title-container {
        width: auto;
        height: auto;
    }

    .whatwedo-title {
        font-size: 2.5rem;
        writing-mode: initial;
        text-align: center;
    }

    .whatwedo-main-content {
        width: 100%;
        max-width: 800px;
    }

    .whatwedo-cards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }

    .whatwedo-card {
        height: 280px;
    }

    .whatwedo-cta {
        justify-content: center;
    }

    /* Disable floating animation on mobile */
    .whatwedo-card:nth-child(odd),
    .whatwedo-card:nth-child(even) {
        animation: none;
    }
}

@media (max-width: 767px) {
    .whatwedo-wrapper {
        gap: 30px;
        padding: 40px 0;
    }

    .whatwedo-title {
        font-size: 2rem;
    }

    .whatwedo-cards-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .whatwedo-card {
        height: 250px;
        max-width: 350px;
        margin: 0 auto;
    }

    .card-title {
        font-size: 1.4rem;
    }

    .overlay-title {
        font-size: 1.4rem;
    }

    .overlay-copy {
        font-size: 0.95rem;
    }

    .overlay-content {
        padding: 20px;
    }

    .overlay-link {
        font-size: 0.9rem;
        justify-content: center;
    }

    /* Show overlay by default on mobile since no hover */
    .whatwedo-card .card-main {
        opacity: 0;
        visibility: hidden;
    }

    .whatwedo-card .card-overlay {
        opacity: 1;
        visibility: visible;
    }
}