/* AI-360 company profile (custom-company-profile)
   Ported from directory-mockup company-profile-*.html — mock-only UI stripped. */

/* 2.1.15: profile breadcrumbs use the shared .breadcrumbs style (custom rules removed) */

/* ---- Profile header ---- */
.dir-profile-header {
    padding-bottom: 56px;
}
.dir-profile-header .subtitle-text-wrapper .circle-separator:last-child {
    display: none;
}
.dir-profile-id {
    display: flex;
    gap: 32px;
    align-items: center;
    margin-top: 18px;
}
.dir-profile-titles {
    min-width: 0;
}
.dir-profile .post-title {
    font-size: 52px;
    font-weight: 600;
    letter-spacing: -0.035em;
    line-height: 110%;
    margin: 0 0 10px;
}
.dir-tagline {
    font-size: 20px;
    line-height: 140%;
    margin: 0;
}

/* ---- Logo circle (contain, not cover — not Circular's crop hero) ---- */
.dir-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
    width: 52%;
    margin: 22px auto 26px;
    border-radius: 50%;
    background: var(--background-color);
    color: var(--text-color1);
    text-decoration: none;
    overflow: hidden;
}
.dir-logo.dir-logo-lg,
.dir-logo-lg {
    width: 150px;
    min-width: 150px;
    height: 150px;
    margin: 0;
    /* Clean shaded badge — soft light ring, not thick black hoop */
    box-shadow: 0 0 0 1px var(--text-color1-20-opacity);
    background: #d4dce6;
}
.dir-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 50%;
    display: block;
    padding: 0;
    box-sizing: border-box;
    background: transparent;
}
.dir-logo-fallback {
    font-family: var(--font2);
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -0.02em;
    text-align: center;
    padding: 12px;
    max-width: 100%;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    opacity: 0.7;
}

/* ---- Body ---- */
.dir-body {
    padding-top: var(--sp-5);
    padding-bottom: var(--sp-7);
    opacity: 1 !important;
}
.dir-body h2 {
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.03em;
    margin: var(--sp-5) 0 14px;
}
.dir-body h2:first-child {
    margin-top: 0;
}
.dir-body p,
.dir-body li {
    font-size: 17px;
    line-height: 160%;
}
.dir-body a {
    color: var(--text-color1);
    text-decoration: underline;
}

/* Soft-label the importer's "Key facts" heading above the table grid */
.dir-profile .dir-body > h2:first-of-type {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    opacity: 0.7;
    margin: 0 0 16px;
}

/* ---- Key facts: native .dir-facts markup (if editor uses it) ---- */
.dir-facts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--text-color1-20-opacity);
    border-left: 1px solid var(--text-color1-20-opacity);
    margin: 0 0 28px;
}
.fact {
    padding: 16px 18px;
    border-right: 1px solid var(--text-color1-20-opacity);
    border-bottom: 1px solid var(--text-color1-20-opacity);
}
.fact small {
    display: block;
    opacity: 0.65;
    font-size: 13px;
    margin-bottom: 4px;
}
.fact div {
    font-weight: 600;
    font-size: 17px;
    line-height: 130%;
}
.fact a {
    color: var(--text-color1);
    text-decoration: underline;
}
.fact-note {
    grid-column: 1 / -1;
    padding: 14px 18px;
    border-right: 1px solid var(--text-color1-20-opacity);
    border-bottom: 1px solid var(--text-color1-20-opacity);
    background: var(--background-color2);
}
.fact-note small {
    display: block;
    opacity: 0.65;
    font-size: 13px;
    margin-bottom: 6px;
}
.fact-note ul {
    margin: 0;
    padding-left: 18px;
}
.fact-note li {
    font-size: 15px;
    line-height: 145%;
    font-weight: 500;
    margin: 0 0 4px;
}
.fact-note li:last-child {
    margin-bottom: 0;
}

/* ---- Key facts: restyle importer <table> into the same grid ---- */
.dir-profile .dir-body > table,
.dir-profile .dir-body > .kg-card-markdown > table,
.dir-profile .dir-body > figure.kg-card > table {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid var(--text-color1-20-opacity);
    border-left: 1px solid var(--text-color1-20-opacity);
    width: 100%;
    max-width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0 0 28px;
    background: transparent;
}
.dir-profile .dir-body > table thead,
.dir-profile .dir-body > table tbody {
    display: contents;
}
.dir-profile .dir-body > table tr {
    display: flex;
    flex-direction: column;
    padding: 16px 18px;
    border-right: 1px solid var(--text-color1-20-opacity);
    border-bottom: 1px solid var(--text-color1-20-opacity);
    background: transparent;
}
.dir-profile .dir-body > table th,
.dir-profile .dir-body > table td {
    border: 0;
    padding: 0;
    background: transparent;
    text-align: left;
    width: auto;
}
.dir-profile .dir-body > table th {
    display: block;
    opacity: 0.65;
    font-size: 13px;
    font-weight: 400;
    font-style: italic;
    margin-bottom: 4px;
    font-family: var(--font2), Georgia, serif;
}
.dir-profile .dir-body > table td {
    display: block;
    font-weight: 600;
    font-size: 17px;
    line-height: 130%;
}
.dir-profile .dir-body > table td a {
    color: var(--text-color1);
    text-decoration: underline;
}

/* Standalone Further facts block (when not inside .dir-facts) */
.dir-profile .dir-body > .fact-note {
    display: block;
    margin: -28px 0 28px;
    border: 1px solid var(--text-color1-20-opacity);
    border-top: 0;
}

/* ---- Body section helpers (used when HTML includes these classes) ---- */
.dir-products {
    padding-left: 20px;
}
.dir-focus {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 6px 0 8px;
}
.dir-focus-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border: 1px solid var(--text-color1-40-opacity);
    border-radius: 100px;
    background: var(--background-color1);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-color1);
    line-height: 1.2;
}
.dir-section-note {
    display: block;
    margin: -4px 0 12px;
    font-size: 13px;
    opacity: 0.65;
}
.dir-ai-use {
    margin: 0 0 4px;
}
.dir-ai-use p {
    margin: 0 0 14px;
}
.dir-ai-use p:last-child {
    margin-bottom: 0;
}
.dir-partners {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 6px 0 8px;
    padding: 0;
    list-style: none;
}
.dir-partners li {
    padding: 8px 14px;
    border: 1px solid var(--text-color1-20-opacity);
    border-radius: 6px;
    background: var(--background-color2);
    font-size: 15px;
    font-weight: 500;
}
.dir-people {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 40px;
    margin-top: 4px;
}
.person {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 12px 0;
    border-bottom: 1px solid var(--text-color1-20-opacity);
}
.person strong {
    font-size: 17px;
    font-weight: 600;
}
.person small {
    display: block;
    opacity: 0.7;
    font-size: 14px;
}
.dir-links {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 30px;
    margin: 0;
}
.dir-links li {
    display: flex;
    gap: 10px;
    align-items: baseline;
}
.dir-links small {
    display: inline-block;
    min-width: 74px;
    opacity: 0.65;
}

/* ---- Disclaimer (always outside paywall — rendered after {{content}}) ---- */
.dir-disclaimer {
    margin: 40px 0 0;
    padding: 16px 18px;
    border: 1px solid var(--text-color1-20-opacity);
    border-radius: 8px;
    background: var(--background-color2);
    font-size: 13px;
    line-height: 155%;
    opacity: 0.85;
}
/* Clear separation from free-member upgrade CTA above */
.dir-profile .post-upgrade-cta ~ .dir-disclaimer {
    margin-top: 40px;
}
.dir-disclaimer strong {
    display: block;
    font-size: 12px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin: 0 0 6px;
    opacity: 0.75;
}
.dir-disclaimer p {
    margin: 0;
    font-size: 13px;
    line-height: 155%;
}

/* ---- Related coverage ---- */
/* Hide coverage section when both sibling #get blocks are empty */
.dir-coverage:not(:has(.dir-related-block)) {
    display: none;
}

/* Both headings ("Coverage of X", "More on this topic") share this rule */
.dir-coverage .section-header {
    margin-bottom: 24px;
}
/* Space above "More on this topic" = the section's own top padding
   (global.css .section-padding), so both headings sit identically */
.dir-related-block + .dir-related-block {
    margin-top: var(--sp-7);
}
/* No company-tagged posts: hide "Coverage of X" so the page doesn't show two headings back to back */
.dir-coverage:not(:has(.dir-related-block:not(.dir-related-secondary))) > .wide-container > .section-header {
    display: none;
}
.dir-related {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
    margin-top: 0;
}
.dir-related-card {
    display: flex;
    gap: 18px;
    align-items: flex-start;
}
/* small-card.css sets .small-card to 22.4vw / 36vw below 1024px, which squeezes the text column */
.dir-related-card.small-card {
    width: 100%;
    min-width: 0;
}
.dir-related-card > div {
    flex: 1 1 auto;
    min-width: 0;
}
.dir-related-img {
    flex: 0 0 110px;
}
.dir-related-img figure {
    margin: 0;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--background-color);
}
.dir-related-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.dir-related-card .medium-text {
    display: block;
    font-size: 19px;
    line-height: 125%;
    margin-bottom: 8px;
    text-decoration: none;
    color: var(--text-color1);
}
.dir-related-card .medium-text:hover {
    text-decoration: underline;
}
.dir-related-card small {
    opacity: 0.75;
}
.dir-related-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font2);
    font-weight: 600;
    font-size: 14px;
    color: var(--text-color1);
    opacity: 0.55;
    background: var(--background-color);
    text-align: center;
    padding: 10px;
    box-sizing: border-box;
    overflow: hidden;
}

/* ---- Gate B: company public HTML is unfaded (no fading-content wrapper).
   Neutralize any residual fade class so Key facts stay fully readable. ---- */
.dir-profile .fading-content {
    max-height: none;
    overflow: visible;
    filter: none;
    opacity: 1;
    user-select: auto;
    pointer-events: auto;
    -webkit-mask-image: none;
    mask-image: none;
}
.dir-profile .fading-content:after {
    display: none;
}
.dir-profile .fading-content + .post-upgrade-cta {
    margin-top: 28px;
    filter: none;
}
.dir-profile .post-upgrade-cta {
    border: 0;
    border-radius: 8px;
    background: var(--ghost-accent-color, #d10f0f);
    color: #ffffff;
    padding: 40px 4vw;
    margin-top: 28px;
}
.dir-profile .post-upgrade-cta h2,
.dir-profile .post-upgrade-cta p,
.dir-profile .post-upgrade-cta small,
.dir-profile .post-upgrade-cta .under-button-wrapper span {
    color: #ffffff;
    opacity: 1;
}
.dir-profile .post-upgrade-cta a.bold-link {
    color: #ffffff;
    text-decoration: underline;
}
.dir-profile .post-upgrade-cta .button {
    background: #ffffff;
    color: var(--ghost-accent-color, #d10f0f);
}
.dir-profile .post-upgrade-cta .button-shadow,
.dir-profile .post-upgrade-cta .button-shadow-dark {
    display: none;
}

/* Optional mock gate helpers if HTML uses them */
.dir-gated {
    position: relative;
}
.dir-teaser {
    max-height: 330px;
    overflow: hidden;
    filter: blur(5px);
    opacity: 0.55;
    user-select: none;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(#000 40%, transparent);
    mask-image: linear-gradient(#000 40%, transparent);
}
.dir-cta {
    margin-top: -120px;
    position: relative;
    z-index: 2;
}
.dir-paid {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    width: 100%;
    margin-top: 14px;
    padding: 22px 26px;
    border: 1px solid var(--text-color1-40-opacity);
    border-radius: 8px;
    background: var(--background-color1);
    color: var(--text-color1);
    text-align: left;
}
.dir-paid small {
    display: block;
    font-size: 15px;
    opacity: 0.75;
    margin-top: 2px;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
    .dir-related {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .dir-profile .post-title {
        font-size: 36px;
    }
    .dir-profile-id {
        gap: 20px;
    }
    .dir-logo.dir-logo-lg,
    .dir-logo-lg {
        width: 110px;
        min-width: 110px;
        height: 110px;
    }
}
@media (max-width: 720px) {
    .dir-facts,
    .dir-profile .dir-body > table {
        grid-template-columns: 1fr 1fr;
    }
    .dir-people,
    .dir-links {
        grid-template-columns: 1fr;
    }
    .dir-profile-id {
        flex-direction: column;
        align-items: flex-start;
    }
}
