/* Services Top Corner (components/services/top_corner.html) — primary cards, corner image expands on hover */
.services-top-corner-section {
    background: #fff;
    padding: 60px 0;
}
.services-top-corner-title {
    text-align: center;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--color-primary);
    margin: 0 0 8px 0;
}
.services-top-corner-subtitle {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 0;
    line-height: 1.5;
}
.services-top-corner-section .row {
    row-gap: 2rem;
}
.services-top-corner-section .row + .row {
    margin-top: 0.5rem;
}
.services-top-corner-section .row > [class*="col-"] {
    margin-bottom: 0.5rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}
.services-top-corner-card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    aspect-ratio: 1 / 1;
    padding: 28px 24px 24px;
    background: var(--color-primary);
    border-radius: var(--border-radius, 16px);
    overflow: hidden;
    color: #fff;
    box-sizing: border-box;
}
.services-top-corner-card.clickable-card {
    cursor: pointer;
}
.services-top-corner-image-wrap {
    position: absolute;
    top: 0;
    right: 0;
    width: 75%;
    height: 75%;
    border-radius: 50%;
    overflow: hidden;
    transform: translate(28%, -28%);
    transition: width 0.5s cubic-bezier(0.22, 1, 0.36, 1),
        height 0.5s cubic-bezier(0.22, 1, 0.36, 1),
        border-radius 0.5s ease,
        transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    z-index: 1;
    pointer-events: none;
}
.services-top-corner-image-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.45s ease;
    z-index: 1;
}
.services-top-corner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.services-top-corner-card:hover .services-top-corner-image-wrap,
.services-top-corner-card:focus-within .services-top-corner-image-wrap {
    width: 100%;
    height: 100%;
    border-radius: 0;
    transform: translate(0, 0);
}
.services-top-corner-card:hover .services-top-corner-image-wrap::after,
.services-top-corner-card:focus-within .services-top-corner-image-wrap::after {
    background: rgba(0, 0, 0, 0.42);
}
.services-top-corner-body {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: calc(100% - 72px);
    margin-top: auto;
}
.services-top-corner-icon {
    font-size: 1.75rem;
    line-height: 1;
    color: #fff;
    margin-bottom: 14px;
}
.services-top-corner-card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 8px 0;
    line-height: 1.3;
}
.services-top-corner-card-subtitle {
    font-size: 0.95rem;
    line-height: 1.2;
    color: rgba(255, 255, 255, 0.92);
    margin: 0;
}
.services-top-corner-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 0;
    font-size: 0.92rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transform: translateY(6px);
    transition: opacity 0.35s ease 0.08s, max-height 0.35s ease, margin-top 0.35s ease, transform 0.35s ease 0.08s;
    pointer-events: none;
}
.services-top-corner-card:hover .services-top-corner-link,
.services-top-corner-card:focus-within .services-top-corner-link {
    opacity: 1;
    max-height: 3rem;
    margin-top: 14px;
    transform: translateY(0);
    pointer-events: auto;
}
.services-top-corner-link:hover {
    color: #fff;
    text-decoration: underline;
}
@media (max-width: 767px) {
    .services-top-corner-section {
        padding: 44px 0;
    }
    .services-top-corner-title {
        font-size: 1.75rem;
    }
    .services-top-corner-section .row {
        row-gap: 1.75rem;
    }
    .services-top-corner-section .row > [class*="col-"] {
        margin-bottom: 1rem;
    }
    .services-top-corner-card {
        padding: 24px 20px 20px;
    }
    .services-top-corner-image-wrap {
        width: 50%;
        height: 50%;
    }
    .services-top-corner-body {
        max-width: calc(100% - 56px);
    }
}
