/*
 * Service cards.
 *
 * Photograph on top, live text below. Everything that can change — the name,
 * how long it takes, the price in this city — is HTML, so a price never has to
 * be redrawn into an image.
 */

.sc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 18px;
}

.sc {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 14px;
    overflow: hidden;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.sc:hover {
    border-color: #CBD5E1;
    box-shadow: 0 8px 22px rgba(15, 23, 42, .07);
    transform: translateY(-2px);
}

.sc:focus-within {
    border-color: var(--sc-badge, #2563EB);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .16);
}

/* The whole upper half is one link, so the card is a single big target. */
.sc-hit {
    display: block;
    padding: 14px 14px 0;
    color: inherit;
    text-decoration: none;
}

.sc-hit:focus-visible { outline: none; }

.sc-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--sc-badge, #334155);
    color: #fff;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    line-height: 1.5;
}

.sc-title {
    margin: 10px 0 12px;
    font-size: 19px;
    font-weight: 800;
    line-height: 1.22;
    letter-spacing: -0.02em;
    color: #0F172A;

    /* Two lines, so every card in a row is the same height whatever the name. */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.44em;
}

.sc-art {
    position: relative;
    aspect-ratio: 20 / 13;
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(150deg, var(--sc-from, #F8FAFC), var(--sc-to, #F1F5F9));
}

.sc-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Shown until a real photograph exists for this service. */
.sc-art-fallback {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sc-badge, #334155);
    opacity: .34;
}

.sc-art-fallback i,
.sc-art-fallback svg {
    width: 54px;
    height: 54px;
    stroke-width: 1.4;
}

.sc-foot {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 14px 14px;
    padding: 9px 10px;
    border: 1px solid #E2E8F0;
    border-radius: 10px;
}

.sc-time {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #64748B;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.sc-time i,
.sc-time svg { width: 13px; height: 13px; }

.sc-price {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
    margin-left: auto;
    text-align: right;
}

.sc-price b {
    font-size: 17px;
    font-weight: 800;
    color: #0F172A;
    font-variant-numeric: tabular-nums;
}

.sc-price small {
    font-size: 10px;
    color: #94A3B8;
}

.sc-form { display: flex; }

.sc-cta {
    padding: 7px 12px;
    border: 0;
    border-radius: 7px;
    background: var(--sc-badge, #2563EB);
    color: #fff;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
    cursor: pointer;
    white-space: nowrap;
    transition: filter .15s ease;
}

.sc-cta:hover { filter: brightness(1.08); }
.sc-cta:active { filter: brightness(.94); }
.sc-cta:focus-visible { outline: 2px solid #0F172A; outline-offset: 2px; }

/* Narrow phones: two per row still works, but the footer needs to stack. */
@media (max-width: 560px) {
    .sc-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
    .sc-title { font-size: 16px; }
    .sc-foot { flex-wrap: wrap; gap: 8px; }
    .sc-price { margin-left: 0; text-align: left; }
    .sc-form { width: 100%; }
    .sc-cta { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .sc, .sc-cta { transition: none; }
    .sc:hover { transform: none; }
}

/* Nobody can do this job yet, so the card offers a call back, not a booking. */
.sc-cta.is-waitlist {
    background: #fff;
    color: #475569;
    border: 1px solid #CBD5E1;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.sc-cta.is-waitlist:hover {
    filter: none;
    border-color: #94A3B8;
    color: #0F172A;
}
