/* Featured Profiles — public carousel + cards */

.profiles-grid {
    --profiles-cols-desktop: 3;
    --profiles-cols-mobile: 1;
    grid-template-columns: repeat(var(--profiles-cols-desktop), minmax(0, 1fr));
}

@media (max-width: 768px) {
    .profiles-grid {
        grid-template-columns: repeat(var(--profiles-cols-mobile), minmax(0, 1fr));
    }
}

.profile-carousel-block {
    --profile-visible-count: 3;
    --profile-card-bg: color-mix(in srgb, var(--surface-bg-card, var(--bg-secondary, #2a2a2a)) 92%, var(--text-primary, #fff) 8%);
    max-width: 100%;
    overflow-x: clip;
}

.profile-carousel {
    position: relative;
    padding: 0 2.75rem;
    max-width: 100%;
    overflow-x: clip;
}

.profile-carousel-track-wrap {
    overflow: hidden;
    overflow-x: clip;
    width: 100%;
    max-width: 100%;
}

.profile-carousel-track {
    display: flex;
    align-items: flex-start;
    transition: transform 0.4s ease;
    will-change: transform;
    touch-action: pan-y pinch-zoom;
}

.profile-carousel-slide {
    flex: 0 0 calc(100% / var(--profile-visible-count));
    min-width: 0;
    padding: 0 0.5rem;
    box-sizing: border-box;
}

/* Single visible slide — cap card width and center (desktop 1-up carousels) */
.profile-carousel-block--single-slide .profile-carousel-slide {
    display: flex;
    justify-content: center;
}

.profile-carousel-block--single-slide .profile-carousel-slide > .profile-card {
    width: 100%;
    max-width: min(100%, 440px);
}

.profile-carousel-block--single-slide .profile-card--display-overlay .offering-image img,
.profile-carousel-block--single-slide .profile-card--display-poster .offering-image img {
    margin-left: auto;
    margin-right: auto;
}

.profile-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: rgba(15, 23, 42, 0.72);
    color: #fff;
    border: none;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.35rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, opacity 0.15s ease;
}

.profile-carousel-btn:hover {
    background: rgba(15, 23, 42, 0.9);
}

.profile-carousel-btn:disabled,
.profile-carousel-btn.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.profile-carousel-btn--prev { left: 0; }
.profile-carousel-btn--next { right: 0; }

.profile-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 1.25rem;
}

.profile-carousel-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    border: none;
    background: rgba(148, 163, 184, 0.55);
    cursor: pointer;
    padding: 0;
}

.profile-carousel-dot.is-active {
    background: var(--color-primary, var(--oso-info, #3b82f6));
    transform: scale(1.15);
}

/* Card layout — direct children for Rise/Forge homepage parity */
.profile-card--carousel,
.profile-card {
    --profile-card-bg: var(--surface-bg-card, var(--bg-secondary, #2a2a2a));
    --profile-card-image-bg: color-mix(in srgb, var(--profile-card-bg) 88%, var(--text-primary, #fff) 12%);
    --profile-card-border: var(--border-color-featured, var(--border-color));
    --profile-card-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
    --profile-card-shadow-hover: 0 16px 40px rgba(0, 0, 0, 0.34);
    height: 100%;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.profile-card-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
}

.profile-card-body h3,
.profile-card-body p {
    margin-top: 0;
}

.profile-card--carousel h3,
.profile-card h3 {
    margin-bottom: 0.35rem;
}

.profile-card--carousel h3 a,
.profile-card h3 a {
    color: inherit;
    text-decoration: none;
}

.profile-card--carousel h3 a:hover,
.profile-card h3 a:hover {
    text-decoration: underline;
}

.profile-card-role,
.profile-card-tagline {
    font-size: 0.9rem;
    opacity: 0.85;
    margin-bottom: 0.35rem;
}

.profile-card-cta {
    margin-top: auto;
    align-self: stretch;
    width: 100%;
    box-sizing: border-box;
}

.profile-card-body .profile-card-cta {
    margin-left: 0;
    margin-right: 0;
    margin-bottom: 0;
    max-width: none;
}

/* Profile cards — full-bleed image, unified shell (carousel + index) */
.profile-card.capability-card,
.profile-card.card {
    overflow: hidden;
}

.profile-card.capability-card:has(.offering-image),
.profile-card.card:has(.offering-image) {
    padding: 0;
    border: var(--border-width-featured, 1px) solid var(--profile-card-border);
    border-radius: var(--border-radius-featured, 16px);
    background: var(--profile-card-bg);
    box-shadow: var(--profile-card-shadow);
}

.profile-card.capability-card:has(.offering-image)::before,
.profile-card.capability-card:has(.offering-image.is-placeholder)::before {
    display: none;
}

.profile-card.capability-card:has(.offering-image):hover,
.profile-card.card:has(.offering-image):hover {
    border-color: var(--profile-card-border);
    transform: none;
    box-shadow: var(--profile-card-shadow-hover);
}

.profile-card .offering-image {
    position: relative;
    aspect-ratio: 4 / 3;
    margin: 0;
    border-radius: 0;
    height: auto;
    width: 100%;
    background: var(--profile-card-image-bg);
    overflow: hidden;
}

.profile-card .offering-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.profile-card-body {
    padding: 1rem 1.25rem 1.25rem;
}

.profile-card--text-filled .profile-card-body {
    background: var(--profile-card-bg);
}

.profile-card--text-transparent .profile-card-body,
.profile-card--text-overlay .profile-card-body {
    background: transparent;
}

.profile-card--display-minimal.profile-card.card:has(.offering-image),
.profile-card--display-minimal.profile-card.capability-card:has(.offering-image) {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
}

.profile-card--display-minimal.profile-card.card:has(.offering-image):hover,
.profile-card--display-minimal.profile-card.capability-card:has(.offering-image):hover {
    box-shadow: none;
}

/* Classic — 4:3 contain */
.profile-card--display-classic .offering-image img {
    object-fit: contain;
}

/* Editorial — 4:3 cover */
.profile-card--display-editorial .offering-image img {
    object-fit: cover;
    position: absolute;
    inset: 0;
}

.profile-card--display-editorial .profile-card-body {
    border-top: 3px solid var(--color-primary, var(--oso-info, #3b82f6));
}

/* Poster — natural height, width-fill */
.profile-card--display-poster .offering-image {
    aspect-ratio: auto;
    height: auto;
    max-height: none;
}

.profile-card--display-poster .offering-image img {
    position: static;
    inset: auto;
    width: 100%;
    height: auto;
    max-height: min(52vh, 420px);
    object-fit: contain;
}

/* Overlay — poster with text on gradient */
.profile-card--display-overlay.profile-card {
    position: relative;
}

.profile-card--display-overlay .offering-image {
    aspect-ratio: auto;
    height: auto;
    min-height: 280px;
}

.profile-card--display-overlay .offering-image img {
    position: static;
    inset: auto;
    width: 100%;
    height: auto;
    min-height: 280px;
    max-height: min(56vh, 460px);
    object-fit: cover;
    object-position: center top;
}

.profile-card--display-overlay .profile-card-body {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 2.5rem 1.25rem 1.25rem;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.88) 0%,
        rgba(0, 0, 0, 0.62) 42%,
        rgba(0, 0, 0, 0) 100%
    );
    color: #fff;
}

.profile-card--display-overlay .profile-card-body h3 a,
.profile-card--display-overlay .profile-card-body h3 {
    color: #fff;
}

.profile-card--display-overlay .profile-card-role,
.profile-card--display-overlay .profile-card-tagline,
.profile-card--display-overlay .profile-card-bio {
    color: rgba(255, 255, 255, 0.9);
    opacity: 1;
}

/* Minimal — natural image height */
.profile-card--display-minimal .offering-image {
    aspect-ratio: auto;
    height: auto;
    background: transparent;
}

.profile-card--display-minimal .offering-image img {
    position: static;
    inset: auto;
    width: 100%;
    height: auto;
    max-height: min(52vh, 420px);
    object-fit: contain;
    border-radius: 12px;
}

.profile-card--display-minimal .profile-card-body {
    padding-left: 0;
    padding-right: 0;
    padding-bottom: 0;
}

/* Rise template overrides for natural-height presets */
.profile-card--display-poster .offering-image,
.profile-card--display-overlay .offering-image,
.profile-card--display-minimal .offering-image {
    margin-bottom: 0;
    border-radius: 0;
}

/* Rise dark homepage — carousel depth (legacy selectors kept for specificity) */
.homepage-block.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image),
.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image),
.homepage-block.profile-carousel-block .profile-card--carousel.card:has(.offering-image),
.profile-carousel-block .profile-card--carousel.card:has(.offering-image) {
    border: var(--border-width-featured, 1px) solid var(--profile-card-border);
    border-radius: var(--border-radius-featured, 16px);
    box-shadow: var(--profile-card-shadow);
}

.homepage-block.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image)::before,
.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image)::before {
    display: none;
}

.homepage-block.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image):hover,
.profile-carousel-block .profile-card--carousel.capability-card:has(.offering-image):hover,
.homepage-block.profile-carousel-block .profile-card--carousel.card:has(.offering-image):hover,
.profile-carousel-block .profile-card--carousel.card:has(.offering-image):hover {
    border-color: var(--profile-card-border);
    transform: none;
    box-shadow: var(--profile-card-shadow-hover);
}

/* Detail page */
.profile-detail.section {
    padding-top: clamp(1.5rem, 4vw, 2.5rem);
    padding-bottom: clamp(2.5rem, 6vw, 4rem);
}

.profile-detail-main {
    max-width: min(100%, 880px);
    margin: 0 auto;
}

.profile-detail-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-subheadline, #94a3b8);
    text-decoration: none;
    transition: color 0.15s ease;
}

.profile-detail-back:hover {
    color: var(--color-primary, var(--accent, #3b82f6));
    text-decoration: none;
}

.profile-detail-shell {
    --profile-shell-bg: var(--surface-bg-card, var(--bg-secondary, #2a2a2a));
    --profile-shell-border: var(--border-color-featured, var(--border-color, rgba(255, 255, 255, 0.12)));
    background: var(--profile-shell-bg);
    border: var(--border-width-featured, 1px) solid var(--profile-shell-border);
    border-radius: var(--border-radius-featured, 16px);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.22);
    overflow: hidden;
}

.profile-detail-layout {
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: clamp(1.25rem, 3.5vw, 2rem);
}

.profile-detail-media {
    margin: calc(-1 * clamp(1.25rem, 3.5vw, 2rem)) calc(-1 * clamp(1.25rem, 3.5vw, 2rem)) 1.5rem;
    overflow: hidden;
    background: color-mix(in srgb, var(--profile-shell-bg) 80%, var(--text-primary, #fff) 20%);
}

.profile-detail-media img {
    display: block;
    width: 100%;
    max-height: min(75vh, 520px);
    object-fit: contain;
    object-position: center top;
}

.profile-detail-identity {
    text-align: center;
    margin-bottom: 1.25rem;
}

.profile-detail-identity h1 {
    margin: 0 0 0.5rem;
    font-size: clamp(1.85rem, 4.5vw, 2.75rem);
    line-height: 1.1;
    letter-spacing: -0.02em;
}

.profile-detail-role {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--color-primary, var(--accent, #3b82f6));
    line-height: 1.4;
}

.profile-detail-tagline {
    margin: 0.4rem 0 0;
    font-size: 1rem;
    opacity: 0.78;
    line-height: 1.5;
}

.profile-detail-bio {
    margin: 0 0 1.75rem;
    padding: 1.15rem 1.25rem;
    border-radius: 12px;
    background: color-mix(in srgb, var(--text-primary, #fff) 4%, transparent);
    border: 1px solid color-mix(in srgb, var(--text-primary, #fff) 8%, transparent);
    text-align: left;
    line-height: 1.65;
    max-width: 100%;
}

.profile-detail-bio > :first-child { margin-top: 0; }
.profile-detail-bio > :last-child { margin-bottom: 0; }
.profile-detail-bio p,
.profile-detail-bio ul,
.profile-detail-bio ol { margin: 0 0 0.85rem; }
.profile-detail-bio h2,
.profile-detail-bio h3 { margin: 1.25rem 0 0.5rem; font-size: 1.1rem; }

.profile-detail-meta {
    margin: 0 0 1.75rem;
    padding-top: 1.5rem;
    border-top: 1px solid color-mix(in srgb, var(--text-primary, #fff) 10%, transparent);
}

.profile-detail-layout > .profile-detail-identity:first-child,
.profile-detail-layout > .profile-detail-media:first-child + .profile-detail-identity {
    margin-top: 0;
}

.profile-detail-layout > .profile-detail-identity:first-child + .profile-detail-bio,
.profile-detail-layout > .profile-detail-media:first-child + .profile-detail-identity + .profile-detail-bio {
    margin-top: 0;
}

.profile-detail-layout > .profile-detail-meta:first-child {
    padding-top: 0;
    border-top: none;
}

.profile-details-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
    gap: 0.75rem;
    margin: 0;
    padding: 0;
}

.profile-details-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    background: color-mix(in srgb, var(--text-primary, #fff) 5%, transparent);
    border: 1px solid color-mix(in srgb, var(--text-primary, #fff) 8%, transparent);
}

.profile-details-list dt {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    opacity: 0.6;
    margin: 0;
}

.profile-details-list dd {
    margin: 0.25rem 0 0;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35;
}

.profile-detail-highlights {
    margin-top: 1.5rem;
}

.profile-detail-subheading {
    margin: 0 0 0.65rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    opacity: 0.65;
    text-align: left;
}

.profile-detail-highlights .profile-detail-subheading:not(:first-child) {
    margin-top: 1.25rem;
}

.profile-detail-list {
    margin: 0;
    padding: 0;
    list-style: none;
    text-align: left;
}

.profile-detail-list li {
    position: relative;
    padding-left: 1.35rem;
    line-height: 1.5;
}

.profile-detail-list li + li {
    margin-top: 0.45rem;
}

.profile-detail-list--checks li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.45em;
    width: 0.55rem;
    height: 0.55rem;
    border-radius: 50%;
    background: var(--color-primary, var(--accent, #3b82f6));
    opacity: 0.85;
}

.profile-detail-callout {
    margin: 1.5rem 0 0;
    padding: 1rem 1.15rem;
    border-left: 3px solid var(--color-primary, var(--accent, #3b82f6));
    border-radius: 0 10px 10px 0;
    background: color-mix(in srgb, var(--color-primary, var(--accent, #3b82f6)) 8%, transparent);
    font-style: normal;
    line-height: 1.55;
    opacity: 0.95;
}

.profile-detail-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.15rem;
    padding-top: 1.5rem;
    border-top: 1px solid color-mix(in srgb, var(--text-primary, #fff) 10%, transparent);
}

.profile-detail-layout > .profile-detail-actions:first-child,
.profile-detail-meta + .profile-detail-actions {
    margin-top: 0;
}

.profile-social-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
    gap: 0.5rem;
    width: 100%;
    max-width: 36rem;
    margin: 0;
}

.profile-social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.55rem 0.65rem;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--text-primary, #fff) 12%, transparent);
    background: color-mix(in srgb, var(--bg-secondary, #2f2f2f) 88%, var(--text-primary, #fff) 12%);
    color: var(--text-primary, inherit);
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 600;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.profile-social-links a:hover {
    border-color: color-mix(in srgb, var(--color-primary, var(--oso-info, #3b82f6)) 45%, transparent);
    background: color-mix(in srgb, var(--color-primary, var(--oso-info, #3b82f6)) 12%, var(--bg-secondary, #2f2f2f));
    text-decoration: none;
    transform: translateY(-1px);
}

.profile-social-links a i {
    font-size: 1rem;
    width: 1rem;
    text-align: center;
}

.profile-detail-cta {
    text-align: center;
    margin: 0;
    width: 100%;
    max-width: 20rem;
}

.profile-detail-cta .btn {
    width: 100%;
    min-width: 12rem;
}

.profile-gallery-wrap {
    padding: clamp(1.25rem, 3vw, 1.75rem) clamp(1.25rem, 3.5vw, 2rem) clamp(1.5rem, 3.5vw, 2rem);
    border-top: 1px solid color-mix(in srgb, var(--text-primary, #fff) 10%, transparent);
    background: color-mix(in srgb, var(--text-primary, #fff) 2%, transparent);
}

.profile-gallery-heading {
    margin: 0 0 1rem;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.65;
    text-align: center;
}

.profile-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 0;
}

.profile-gallery-item {
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid color-mix(in srgb, var(--text-primary, #fff) 8%, transparent);
    background: var(--bg-secondary, #2f2f2f);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.profile-gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

.profile-gallery-item img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

/* Default — centered single column */
.profile-detail--default .profile-detail-media img {
    max-width: min(100%, 420px);
    margin: 0 auto;
}

.profile-detail--default .profile-detail-media {
    display: flex;
    justify-content: center;
    background: transparent;
}

/* Hero — full-width banner */
.profile-detail--hero .profile-detail-media {
    margin-left: calc(-1 * clamp(1.25rem, 3.5vw, 2rem));
    margin-right: calc(-1 * clamp(1.25rem, 3.5vw, 2rem));
    margin-top: calc(-1 * clamp(1.25rem, 3.5vw, 2rem));
    margin-bottom: 0;
    position: relative;
    max-height: 420px;
}

.profile-detail--hero .profile-detail-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, var(--profile-shell-bg) 0%, transparent 55%);
    pointer-events: none;
}

.profile-detail--hero .profile-detail-media img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    object-position: center top;
}

.profile-detail--hero .profile-detail-identity {
    margin-top: -2.5rem;
    position: relative;
    z-index: 1;
    padding: 0 0.5rem;
}

.profile-detail--hero .profile-detail-layout {
    padding-top: 0;
}

.profile-detail--hero .profile-detail-layout > .profile-detail-bio,
.profile-detail--hero .profile-detail-layout > .profile-detail-meta,
.profile-detail--hero .profile-detail-layout > .profile-detail-actions {
    padding-left: clamp(1.25rem, 3.5vw, 2rem);
    padding-right: clamp(1.25rem, 3.5vw, 2rem);
}

.profile-detail--hero .profile-detail-layout > .profile-detail-bio:first-of-type {
    padding-top: 1.25rem;
}

/* Split — two columns on desktop */
@media (min-width: 900px) {
    .profile-detail--split .profile-detail-layout:has(.profile-detail-media) {
        display: grid;
        grid-template-columns: minmax(240px, 0.42fr) minmax(0, 1fr);
        grid-template-areas:
            "media identity"
            "media bio"
            "meta bio"
            "meta actions";
        column-gap: 2rem;
        row-gap: 1.25rem;
        align-items: start;
    }

    .profile-detail--split .profile-detail-media {
        grid-area: media;
        margin: 0;
        border-radius: 12px;
        position: sticky;
        top: 1.5rem;
    }

    .profile-detail--split .profile-detail-media img {
        border-radius: 12px;
        max-height: min(70vh, 480px);
        object-fit: cover;
    }

    .profile-detail--split .profile-detail-identity {
        grid-area: identity;
        text-align: left;
        margin-bottom: 0;
    }

    .profile-detail--split .profile-detail-bio {
        grid-area: bio;
        margin-bottom: 0;
    }

    .profile-detail--split .profile-detail-meta {
        grid-area: meta;
        margin-bottom: 0;
        padding-top: 0;
        border-top: none;
    }

    .profile-detail--split .profile-detail-actions {
        grid-area: actions;
        align-items: flex-start;
        padding-top: 0;
        border-top: none;
    }

    .profile-detail--split .profile-social-links {
        justify-items: stretch;
    }

    .profile-detail--split .profile-detail-cta {
        max-width: 100%;
    }
}

.profile-related {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid color-mix(in srgb, var(--text-primary, #fff) 10%, transparent);
}

.profile-related > h2 {
    text-align: center;
    margin: 0 0 1.5rem;
    font-size: clamp(1.25rem, 3vw, 1.5rem);
}

/* Index page */
.profiles-index-section--modern {
    padding-top: clamp(2rem, 5vw, 3rem);
    padding-bottom: clamp(2.5rem, 6vw, 4rem);
}

.profiles-index-section--modern .section-title {
    margin-bottom: clamp(1.5rem, 4vw, 2.25rem);
}

.profiles-index-section--modern .section-title h1 {
    margin-bottom: 0.5rem;
    font-size: clamp(1.85rem, 4.5vw, 2.5rem);
    letter-spacing: -0.02em;
}

.profiles-index-section--modern .section-title .subheadline {
    max-width: 40rem;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.55;
}

.profiles-index-intro {
    max-width: 42rem;
    margin: 0 auto 2rem;
    text-align: center;
    line-height: 1.65;
    opacity: 0.9;
}

.profiles-index-intro > :first-child { margin-top: 0; }
.profiles-index-intro > :last-child { margin-bottom: 0; }

.profiles-index-section--modern .profiles-index {
    margin-top: 0.5rem;
}

.profiles-layout-featured_plus_grid > .profile-card--featured {
    margin-bottom: 2rem;
}

.profiles-layout-editorial .profiles-grid {
    gap: 1.5rem;
}

/* Index layout: List — single-column stacked rows */
.profiles-layout-list .profiles-grid {
    --profiles-cols-desktop: 1;
    --profiles-cols-mobile: 1;
    grid-template-columns: 1fr;
    gap: 1rem;
    max-width: 52rem;
    margin-left: auto;
    margin-right: auto;
}

.profiles-layout-list .profile-card.capability-card:has(.offering-image),
.profiles-layout-list .profile-card.card:has(.offering-image) {
    display: grid;
    grid-template-columns: minmax(120px, 220px) minmax(0, 1fr);
    align-items: stretch;
    height: auto;
}

.profiles-layout-list .profile-card .offering-image {
    position: relative;
    aspect-ratio: auto;
    min-height: 140px;
    height: 100%;
}

.profiles-layout-list .profile-card .offering-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
}

.profiles-layout-list .profile-card .offering-image.is-placeholder .offering-image-fallback,
.profiles-layout-list .profile-card .offering-image-fallback {
    position: absolute;
    inset: 0;
}

.profiles-layout-list .profile-card-body {
    justify-content: center;
    padding: 1.15rem 1.35rem;
}

.profiles-layout-list .profile-card--display-overlay .offering-image {
    min-height: 140px;
    max-height: none;
}

.profiles-layout-list .profile-card--display-overlay .offering-image img {
    min-height: 140px;
    max-height: none;
    object-fit: cover;
}

.profiles-layout-list .profile-card--display-overlay .profile-card-body {
    position: static;
    left: auto;
    right: auto;
    bottom: auto;
    background: var(--profile-card-bg);
    color: inherit;
    padding: 1.15rem 1.35rem;
}

.profiles-layout-list .profile-card--display-overlay .profile-card-body h3,
.profiles-layout-list .profile-card--display-overlay .profile-card-body h3 a {
    color: inherit;
}

.profiles-layout-list .profile-card--display-overlay .profile-card-role,
.profiles-layout-list .profile-card--display-overlay .profile-card-tagline,
.profiles-layout-list .profile-card--display-overlay .profile-card-bio {
    color: inherit;
    opacity: 0.85;
}

.profiles-layout-list .profile-card--display-poster .offering-image,
.profiles-layout-list .profile-card--display-minimal .offering-image {
    aspect-ratio: auto;
    height: 100%;
}

.profiles-layout-list .profile-card--display-poster .offering-image img,
.profiles-layout-list .profile-card--display-minimal .offering-image img {
    max-height: none;
    height: 100%;
    object-fit: cover;
}

.profiles-layout-list .profile-card--display-minimal.profile-card.card:has(.offering-image),
.profiles-layout-list .profile-card--display-minimal.profile-card.capability-card:has(.offering-image) {
    background: var(--profile-card-bg);
    border-color: var(--profile-card-border);
    box-shadow: var(--profile-card-shadow);
}

.profiles-layout-list .profile-card--display-minimal .offering-image img {
    border-radius: 0;
}

.profiles-layout-list .profile-card--display-minimal .profile-card-body {
    padding: 1.15rem 1.35rem;
}

@media (max-width: 640px) {
    .profiles-layout-list .profile-card.capability-card:has(.offering-image),
    .profiles-layout-list .profile-card.card:has(.offering-image) {
        grid-template-columns: 1fr;
    }

    .profiles-layout-list .profile-card .offering-image {
        min-height: 180px;
        aspect-ratio: 16 / 9;
        height: auto;
    }
}

.profiles-index-empty {
    text-align: center;
    padding: 2.5rem 1rem;
    opacity: 0.75;
    font-size: 1.05rem;
}

@media (max-width: 768px) {
    .profile-detail--hero .profile-detail-media {
        max-height: 280px;
    }

    .profile-detail--hero .profile-detail-media img {
        max-height: 280px;
    }

    .profile-detail--hero .profile-detail-identity {
        margin-top: -1.5rem;
    }

    .profile-social-label {
        display: none;
    }

    .profile-social-links {
        grid-template-columns: repeat(auto-fit, minmax(2.75rem, 1fr));
        max-width: 100%;
    }

    .profile-social-links a {
        padding: 0.65rem;
        aspect-ratio: 1;
    }

    .profile-details-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .profile-gallery {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    }

    .profile-carousel {
        padding: 0 2.25rem;
    }
    .profile-carousel-btn {
        width: 2rem;
        height: 2rem;
        font-size: 1.1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .profile-carousel-track {
        transition: none;
    }
}
