/* Public agency marketplace (Marketplace.Web). Builds on platform.css (--ahp-* tokens, .ahp-card). */

.mkt-hero {
    display: grid;
    gap: 1.25rem;
    padding: 2rem 1.75rem;
    margin-bottom: 1.25rem;
    border-radius: 14px;
    color: #fff;
    background: radial-gradient(circle at 85% 10%, color-mix(in srgb, var(--ahp-app) 55%, white) 0, transparent 40%),
                linear-gradient(135deg, var(--ahp-app), color-mix(in srgb, var(--ahp-app) 55%, #14233a));
}

.mkt-hero h1 { font-size: 1.75rem; font-weight: 650; margin: 0 0 .35rem; }
.mkt-hero p { margin: 0; max-width: 46rem; opacity: .92; }

.mkt-search { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.mkt-search > input { flex: 1 1 18rem; min-width: 0; height: 38px; }
.mkt-search .e-ddl { background: #fff; }

.mkt-groups { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }

.mkt-group {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .8rem;
    border: 1px solid var(--ahp-border);
    border-radius: 999px;
    background: var(--ahp-card);
    color: var(--ahp-text);
    font-size: .85rem;
}

.mkt-group:hover { border-color: var(--ahp-app); }
.mkt-group.active { background: var(--ahp-app); border-color: var(--ahp-app); color: #fff; }
.mkt-group .bi { font-size: .95rem; }

.mkt-type-filter { max-width: 100%; }

.mkt-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
    gap: 1rem;
}

.mkt-card {
    display: flex;
    flex-direction: column;
    gap: .6rem;
    padding: 1.1rem;
    border: 1px solid var(--ahp-border);
    border-radius: 12px;
    background: var(--ahp-card);
    color: var(--ahp-text);
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.mkt-card:hover { color: var(--ahp-text); transform: translateY(-2px); border-color: var(--ahp-app); box-shadow: 0 8px 20px rgba(20, 35, 60, .1); }

.mkt-card-head { display: flex; gap: .75rem; align-items: flex-start; }
.mkt-card-head .min-w-0 { min-width: 0; }

.mkt-card-icon {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--ahp-app) 14%, white);
    color: var(--ahp-app);
    font-size: 1.25rem;
}

.mkt-card-icon-lg { width: 64px; height: 64px; font-size: 1.9rem; border-radius: 14px; }

.mkt-card-title { font-weight: 600; font-size: 1.05rem; line-height: 1.25; }
.mkt-card-type { color: var(--ahp-muted); font-size: .8rem; }
.mkt-card-tagline { margin: 0; font-size: .9rem; }
.mkt-card-meta { display: flex; flex-wrap: wrap; gap: .25rem 1rem; color: var(--ahp-muted); font-size: .8rem; }
.mkt-card-meta .bi { margin-right: .3rem; }
.mkt-card-go { margin-top: auto; color: var(--ahp-app); font-size: .85rem; font-weight: 600; }

.mkt-badges { display: flex; flex-wrap: wrap; gap: .35rem; }
.mkt-badges .badge { font-weight: 500; }

.mkt-join {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.75rem;
    padding: 1.25rem 1.5rem;
}

.mkt-join h2 { font-size: 1.15rem; font-weight: 600; margin: 0 0 .35rem; }

.mkt-detail { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 1rem; align-items: start; }

.mkt-detail-head { display: flex; gap: 1rem; padding: 1.25rem; }
.mkt-detail-head h1 { font-size: 1.5rem; font-weight: 650; margin: 0; }
.mkt-detail-tagline { margin: .5rem 0 .6rem; }

.mkt-facts { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1rem; margin: 0; }
.mkt-facts dt { color: var(--ahp-muted); font-weight: 500; font-size: .85rem; }
.mkt-facts dd { margin: 0; }

.mkt-inquiry { position: sticky; top: 1rem; }

@media (max-width: 900px) {
    .mkt-detail { grid-template-columns: 1fr; }
    .mkt-inquiry { position: static; }
}
