/* Specialist profile — Figma 459:6092 (1440) · 464:6423 (1024) · 464:6919 (768) · 464:7387 (390) */

main.expertpress-public-specialists:has(> .md-prof) { max-width: none; margin: 0; padding: 0; background: var(--md-color-bg-surface); }
.md-prof { --svc-gutter: 120px; color: var(--md-color-text-primary); font-family: var(--md-font-sans); padding-bottom: 72px; }
.md-prof .md-shell { width: min(1200px, calc(100% - 2 * var(--svc-gutter))); margin-inline: auto; }
.md-prof h1, .md-prof h2, .md-prof h3, .md-prof p { margin: 0; }
.md-prof ul, .md-prof ol, .md-prof dl { list-style: none; margin: 0; padding: 0; }
.md-prof [hidden] { display: none !important; }

/* Hero */
.md-prof-hero { display: grid; grid-template-columns: 240px minmax(0, 1fr) 320px; gap: 40px; align-items: stretch; padding: 24px 0 48px; }
.md-prof-photo { position: relative; width: 240px; height: 288px; border-radius: 28px; overflow: hidden; background: linear-gradient(138deg, #eee9f3 7%, #e8ddd0 79%); box-shadow: 0 18px 40px rgba(46, 38, 56, .12); }
.md-prof-photo > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.md-prof-photo .md-prof-photo__placeholder { object-fit: contain; }
.md-prof-photo__fav { top: 13px; right: 13px; }
.md-prof-photo form { display: contents; }
button.md-heart { border: 0; cursor: pointer; }
.md-prof-id { min-width: 0; padding-top: 8px; }
.md-prof-id__eyebrow { color: var(--md-color-action-primary-bg); font: 700 11px/16px var(--md-font-sans); letter-spacing: 2.2px; text-transform: uppercase; }
.md-prof-id__name { margin-top: 10px !important; font: 400 48px/56px var(--md-font-serif); overflow-wrap: anywhere; }
.md-prof-id__meta { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 18px !important; color: var(--md-color-text-secondary); font: 600 14px/20px var(--md-font-sans); }
.md-prof-id__meta li { display: inline-flex; align-items: center; gap: 6px; }
.md-prof-id__meta b { color: var(--md-color-text-primary); font-weight: 700; }
.md-prof-id__dirs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px !important; }
.md-prof-panel { display: flex; flex-direction: column; padding: 18px 22px 22px; border: 1px solid var(--md-color-border-default); border-radius: 24px; background: var(--md-color-bg-canvas); }
.md-prof-facts > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; }
.md-prof-facts > div + div { border-top: 1px solid var(--md-color-border-default); }
.md-prof-facts dt { color: var(--md-color-text-secondary); font-size: 14px; line-height: 21px; }
.md-prof-facts dd { margin: 0; font: 600 15px/19px var(--md-font-sans); text-align: right; }
.md-prof-facts__short, .md-prof-price-short { display: none; }
.md-prof-actions { display: flex; flex-direction: column; gap: 10px; margin-top: auto; padding-top: 24px; }
.md-prof-actions .md-button { width: 100%; height: 48px; border-radius: 24px; font: 600 14px/20px var(--md-font-sans); }
.md-prof-actions [aria-disabled="true"] { cursor: default; }

/* Tabs */
.md-prof-tabs { position: sticky; top: 0; z-index: 20; border-top: 1px solid var(--md-color-border-default); border-bottom: 1px solid var(--md-color-border-default); background: var(--md-color-bg-surface); }
.md-prof-tabs .md-shell { display: flex; gap: 36px; height: 64px; align-items: flex-end; }
.md-prof-tabs a { display: flex; flex-direction: column; gap: 8px; padding-top: 10px; color: var(--md-color-text-secondary); font: 600 14px/20px var(--md-font-sans); text-decoration: none; }
.md-prof-tabs a::after { content: ""; height: 2px; margin-bottom: 11px; background: var(--md-color-action-soft-hover); }
.md-prof-tabs a.is-active { color: var(--md-color-action-primary-bg); }
.md-prof-tabs a.is-active::after { background: var(--md-color-action-primary-bg); }
.md-prof [id] { scroll-margin-top: 80px; }

/* About + experience */
.md-prof-about { display: grid; grid-template-columns: minmax(0, 555px) minmax(0, 605px); justify-content: space-between; gap: 40px; padding-top: 32px; }
.md-prof-about--solo { grid-template-columns: minmax(0, 760px); }
.md-prof-about h2, .md-prof-section > h2 { font: 400 34px/40px var(--md-font-serif); }
.md-prof-collapse { margin-top: 10px; }
.md-prof-collapse__body { position: relative; }
.md-prof-collapse.is-clamped .md-prof-collapse__body { max-height: var(--md-clamp, 278px); overflow: hidden; }
.md-prof-collapse.is-clamped .md-prof-collapse__body::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 68px; background: linear-gradient(180deg, rgba(255, 253, 252, 0), var(--md-color-bg-surface)); }
.md-prof-soft { display: inline-flex; height: 48px; gap: 10px; margin-top: 16px; padding: 0 22px 0 24px; border: 0; border-radius: 24px; background: var(--md-color-action-soft-bg); color: var(--md-color-action-primary-bg); font: 600 14px/20px var(--md-font-sans); cursor: pointer; }
.md-prof-soft[aria-expanded="true"] .md-icon { transform: rotate(180deg); }
.md-prof-exp { align-self: start; padding: 23px 25px 25px; border: 1px solid var(--md-color-border-default); border-radius: 24px; background: var(--md-color-bg-canvas); }
.md-prof-exp h3 { font: 700 14px/20px var(--md-font-sans); }
.md-prof-exp ul { margin-top: 8px !important; }
.md-prof-exp li { display: flex; gap: 10px; padding: 8px 0 9px; font-size: 15px; line-height: 22px; }
.md-prof-exp li + li { border-top: 1px solid var(--md-color-border-default); }
.md-prof-exp li .md-icon { flex: none; margin-top: 2px; color: var(--md-color-action-primary-bg); }
.md-prof-exp .md-prof-soft { margin-top: 8px; }
.md-prof-exp__note { display: flex; gap: 8px; margin-top: 12px !important; padding: 10px 12px; border-radius: 14px; background: var(--md-color-bg-surface); color: var(--md-color-text-secondary); font: 500 12px/18px var(--md-font-sans); }
.md-prof-exp__note .md-icon { flex: none; margin-top: 1px; }

/* Sections */
.md-prof-section { padding-top: 32px; }
.md-prof-section__sub { margin-top: 4px !important; color: var(--md-color-text-secondary); font-size: 14px; line-height: 21px; }
.md-prof-services { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; gap: 24px !important; margin-top: 22px !important; }
.md-prof-services .md-scard__author { display: none; }
.md-prof-reviews { margin-top: 22px; gap: 40px; }
.md-prof-reviews .md-svc-score { width: 300px; }
.md-prof-reviews__more { align-self: center; margin-top: 2px; }
.md-prof-others { grid-template-columns: repeat(5, minmax(0, 1fr)) !important; gap: 20px !important; margin-top: 22px !important; }
.md-prof-empty { align-items: flex-start; margin-top: 22px; padding: 32px; text-align: left; }

@media (max-width: 1199px) {
	.md-prof { --svc-gutter: 48px; }
	.md-prof-hero { grid-template-columns: 210px minmax(0, 1fr); gap: 20px 32px; }
	.md-prof-photo { width: 210px; height: 252px; }
	.md-prof-id__name { font-size: 40px; line-height: 46px; }
	.md-prof-panel { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 24px; padding: 14px 20px; }
	.md-prof-facts { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
	.md-prof-facts > div { flex-direction: column; align-items: flex-start; gap: 2px; padding: 0; }
	.md-prof-facts > div + div { border-top: 0; }
	.md-prof-facts dt { font-size: 12px; line-height: 16px; }
	.md-prof-facts dd { text-align: left; }
	.md-prof-actions { flex-direction: row; width: 420px; margin: 0; padding: 0; }
	.md-prof-about { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; }
	.md-prof-services { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
	.md-prof-others { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
	.md-prof-others > li:nth-child(n+5) { display: none; }
	.md-prof-reviews { flex-direction: row; }
	.md-prof-reviews .md-svc-score { width: 240px; }
}

@media (max-width: 1023px) {
	.md-prof { --svc-gutter: 32px; }
	.md-prof-hero { grid-template-columns: 190px minmax(0, 1fr); padding-bottom: 32px; }
	.md-prof-photo { width: 190px; height: 228px; }
	.md-prof-panel { display: contents; }
	.md-prof-photo { grid-column: 1; grid-row: 1; }
	.md-prof-id { grid-column: 2; grid-row: 1 / span 2; }
	.md-prof-actions { grid-column: 1; grid-row: 2; width: auto; flex-direction: column; margin: 0; padding: 0; }
	.md-prof-facts { grid-column: 1 / -1; grid-row: 3; }
	.md-prof-facts > div { padding: 12px 16px; border: 1px solid var(--md-color-border-default); border-radius: 16px; }
	.md-prof-about { grid-template-columns: minmax(0, 1fr); }
	.md-prof-services { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
	.md-prof-others { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; }
	.md-prof-others > li:nth-child(n+4) { display: none; }
	.md-prof-reviews { flex-direction: column; gap: 16px; }
	.md-prof-reviews .md-svc-score { width: 100%; }
}

@media (max-width: 767px) {
	.md-prof { --svc-gutter: 20px; padding-bottom: 48px; }
	.md-prof-hero { grid-template-columns: 128px minmax(0, 1fr); gap: 16px; padding: 12px 0 24px; }
	.md-prof-photo { width: 128px; height: 156px; border-radius: 20px; }
	.md-prof-photo__fav { top: 8px; right: 8px; }
	.md-prof-id { display: contents; }
	.md-prof-id__eyebrow, .md-prof-id__name { grid-column: 2; }
	.md-prof-id__eyebrow { align-self: end; font-size: 10px; letter-spacing: 1.6px; }
	.md-prof-id__name { align-self: start; margin-top: 0 !important; font-size: 26px; line-height: 30px; }
	.md-prof-hero > .md-prof-photo { grid-row: 1 / span 2; }
	.md-prof-id__meta, .md-prof-id__dirs, .md-prof-panel { grid-column: 1 / -1; }
	.md-prof-id__meta { margin-top: 0 !important; gap: 6px 16px; font-size: 13px; }
	.md-prof-id__dirs { margin-top: 0 !important; }
	.md-prof-panel { display: flex; flex-direction: column-reverse; align-items: stretch; gap: 14px; padding: 0; border: 0; border-radius: 0; background: none; }
	.md-prof-actions { width: 100%; }
	.md-prof-actions .md-button { white-space: nowrap; padding: 0 16px; }
	.md-prof-facts > div { justify-content: flex-start; }
	.md-prof-price-long { display: none; }
	.md-prof-price-short { display: inline !important; }
	.md-prof-actions, .md-prof-facts { grid-column: auto; grid-row: auto; }
	.md-prof-actions { width: auto; flex-direction: row; }
	.md-prof-actions .md-button--primary { flex: 1.6; }
	.md-prof-actions .md-button--secondary { flex: 1; }
	.md-prof-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
	.md-prof-facts > div { padding: 10px 12px; }
	.md-prof-facts dd { font-size: 14px; line-height: 18px; }
	.md-prof-facts dd:has(.md-prof-facts__short) { font-size: 0; }
	.md-prof-facts__short { display: inline; font-size: 14px; }
	.md-prof-tabs .md-shell { gap: 28px; height: 56px; }
	.md-prof-about h2, .md-prof-section > h2 { font-size: 28px; line-height: 34px; }
	.md-prof-about { padding-top: 24px; gap: 24px; }
	.md-prof-section { padding-top: 28px; }
	.md-prof-services { grid-template-columns: minmax(0, 1fr) !important; gap: 12px !important; }
	.md-prof-others { grid-template-columns: minmax(0, 1fr) !important; gap: 12px !important; }
	.md-prof-reviews__more { width: 100%; }
}

/* Certificates inside «Досвід і навчання» (Figma 464:6423): three thumbnails per row with a caption. */
.md-prof-exp .md-prof-certs__head { margin-top: 20px; }
.md-prof-exp .md-prof-certs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 8px; margin-top: 10px !important; }
.md-prof-exp .md-prof-certs li { display: flex; flex-direction: column; gap: 6px; padding: 0; border: 0; font: 400 12px/16px var(--md-font-sans); color: var(--md-color-text-secondary); overflow-wrap: anywhere; }
.md-prof-exp .md-prof-certs li + li { border-top: 0; }
.md-prof-certs a { display: block; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--md-color-bg-surface); }
.md-prof-certs a:focus-visible { outline: 2px solid var(--md-color-focus-ring); outline-offset: 2px; }
.md-prof-certs img { display: block; width: 100%; height: 100%; object-fit: cover; }
.md-prof-certs__hint { margin-top: 8px !important; font: 400 12px/18px var(--md-font-sans); color: var(--md-color-text-secondary); }

/* Certificate viewer (dialog). */
.md-cert-view { padding: 0; border: 0; background: transparent; max-width: min(960px, calc(100vw - 32px)); max-height: calc(100vh - 32px); }
.md-cert-view::backdrop { background: rgba(20, 16, 26, 0.72); }
.md-cert-view__box { position: relative; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.md-cert-view__img { display: block; max-width: 100%; max-height: calc(100vh - 110px); width: auto; height: auto; border-radius: var(--md-radius-12); background: var(--md-color-bg-surface); }
.md-cert-view__title { margin: 0 !important; font: 500 14px/20px var(--md-font-sans); color: #fff; text-align: center; }
.md-cert-view__close { position: absolute; top: 8px; right: 8px; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 0; border-radius: var(--md-radius-full); background: rgba(255, 255, 255, 0.92); color: #2f2737; cursor: pointer; box-shadow: var(--md-shadow-card); }
.md-cert-view__close:focus-visible { outline: 2px solid var(--md-color-focus-ring); outline-offset: 2px; }

/* Video intro (VI-1b, Figma «5 · Сторінка спеціаліста», v2 · відео-знайомство): pill on the photo + button under the directions. */
.md-prof-intro-pill { position: absolute; left: 10px; bottom: 14px; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px 0 10px; border: 0; border-radius: var(--md-radius-full); background: rgba(255, 255, 255, 0.88); color: var(--md-color-action-primary-bg, #5a4b7a); font: 600 13px/18px var(--md-font-sans); box-shadow: 0 4px 14px rgba(41, 23, 64, 0.22); cursor: pointer; }
.md-prof-intro-pill::before { content: ""; position: absolute; inset: -6px; }
.md-prof-intro { display: inline-flex; align-items: center; gap: 8px; height: 44px; margin-top: 16px; padding: 0 20px; border: 1px solid #d9d0ea; border-radius: var(--md-radius-full); background: #fff; color: var(--md-color-action-primary-bg, #5a4b7a); font: 600 14px/20px var(--md-font-sans); cursor: pointer; }
.md-prof-intro:hover, .md-prof-intro-pill:hover { background: #fff; border-color: var(--md-color-action-primary-bg, #5a4b7a); }
.md-prof-intro:focus-visible { outline: 2px solid var(--md-color-focus-ring); outline-offset: 2px; }
.md-intro-view { padding: 0; border: 0; background: transparent; max-width: calc(100vw - 32px); max-height: calc(100vh - 32px); overflow: visible; }
.md-intro-view::backdrop { background: rgba(20, 16, 26, 0.78); }
.md-intro-view__box { position: relative; display: flex; flex-direction: column; gap: 16px; width: min(960px, calc(100vw - 32px)); }
.md-intro-view.is-portrait .md-intro-view__box { width: min(400px, calc(100vw - 32px), calc((100vh - 140px) * 9 / 16)); }
.md-intro-view__frame { position: relative; width: 100%; max-height: calc(100vh - 140px); border-radius: 24px; overflow: hidden; background: #1c1b23; }
.md-intro-view__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.md-intro-view__state { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; margin: 0 !important; padding: 24px; color: #fff; font: 500 14px/20px var(--md-font-sans); text-align: center; }
.md-intro-view__close { position: absolute; top: 0; right: -60px; display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border: 0; border-radius: var(--md-radius-full); background: rgba(255, 255, 255, 0.92); color: #2f2737; cursor: pointer; box-shadow: var(--md-shadow-card); }
.md-intro-view__close:focus-visible { outline: 2px solid var(--md-color-focus-ring); outline-offset: 2px; }
.md-intro-view__foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
@media (max-width: 1079px) {
	/* No room beside the box: the close button sits inside, over the player corner. */
	.md-intro-view__close { top: 12px; right: 12px; z-index: 1; }
}
.md-intro-view__name { margin: 0 !important; font: 400 22px/28px var(--md-font-serif); color: #fff; }
.md-intro-view__sub { margin: 2px 0 0 !important; font: 500 13px/18px var(--md-font-sans); color: rgba(255, 255, 255, 0.78); }
@media (max-width: 767px) {
	.md-prof-intro-pill { left: 8px; bottom: 8px; height: 32px; padding: 0 10px 0 8px; font-size: 12px; }
	.md-prof-intro-pill::before { inset: -8px; }
	.md-prof-hero > .md-prof-id .md-prof-intro { grid-column: 1 / -1; width: 100%; justify-content: center; margin-top: 0; }
	.md-intro-view { max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; margin: 0; }
	.md-intro-view__box, .md-intro-view.is-portrait .md-intro-view__box { width: 100vw; height: 100vh; justify-content: center; padding: 64px 16px 16px; }
	.md-intro-view__frame { max-height: calc(100vh - 170px); margin: 0 auto; }
	.md-intro-view.is-portrait .md-intro-view__frame { width: auto; height: calc(100vh - 170px); max-width: 100%; }
	.md-intro-view__close { top: 12px; right: 12px; }
	.md-intro-view__foot { flex-direction: column; align-items: stretch; }
	.md-intro-view__foot .md-button { width: 100%; }
}
