/* The new public profile (shown while MINDSTICK_NEW_PROFILE=1). It restyles the hero of the one existing profile page into the submitted design: a navy
   header with a large rounded avatar, the PRO chip beside the name and light text. It only changes colours, sizes and layout: no markup of the
   existing page is duplicated, so there is never a second profile UI. When the new design is signed off this file is merged into qa-profile.css. */

.qa-user-page--v2 .qa-user-hero {
    background: #0F2A55;
    color: #FFFFFF;
    border-radius: 16px;
    padding: 0 0 28px;
    overflow: hidden;
    gap: 0;
}

/* the cover picture the user uploaded stays, as a slimmer strip along the top */
.qa-user-page--v2 .qa-user-hero__banner { margin: 0; height: 140px; border-radius: 0; width: 100%; }
.qa-user-page--v2 .qa-user-hero__banner img { width: 100%; height: 100%; object-fit: cover; opacity: .85; }

/* avatar and name row sit on the cover, side by side */
.qa-user-page--v2 .qa-user-hero__top { padding: 0 28px; margin-top: -44px; align-items: flex-end; gap: 20px; flex-wrap: wrap; }
.qa-user-page--v2 .qa-user-hero__avatar img,
.qa-user-page--v2 .qa-user-hero__avatar .qa-avatar { width: 96px; height: 96px; border-radius: 20px; border: 4px solid #0F2A55; background: #FFFFFF; }
.qa-user-page--v2 .qa-user-hero__badge { background: #FFFFFF; color: #0F2A55; }

.qa-user-page--v2 .qa-user-hero__name-row { flex: 1 1 420px; padding-top: 52px; align-items: center; flex-wrap: wrap; gap: 12px; }
.qa-user-page--v2 .qa-user-hero__name { color: #FFFFFF; font-size: 30px; font-weight: 800; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }

/* details under the avatar */
.qa-user-page--v2 .qa-user-hero__info { padding: 14px 28px 0; gap: 8px; }
.qa-user-page--v2 .qa-user-hero__designation { color: #D6E2F5; font-size: 16px; }
.qa-user-page--v2 .qa-user-hero__about { color: #D6E2F5; }
.qa-user-page--v2 .qa-user-hero__meta,
.qa-user-page--v2 .qa-user-hero__meta-item { color: #B6C6E3; font-size: 13px; }
.qa-user-page--v2 .qa-user-hero__meta-item a { color: #FFFFFF; }
.qa-user-page--v2 .qa-user-hero__add-link,
.qa-user-page--v2 .qa-user-hero__edit-icon { color: #B6C6E3; }
.qa-user-page--v2 .qa-user-hero .qa-tag { background: rgba(255, 255, 255, .12); color: #FFFFFF; border-color: transparent; }
.qa-user-page--v2 .qa-user-social { color: #FFFFFF; border-color: #4A6290; }

/* buttons on the dark header: the main one is white, the rest are outlined */
.qa-user-page--v2 .qa-user-hero__actions .qa-btn { border-color: #4A6290; color: #FFFFFF; background: transparent; }
.qa-user-page--v2 .qa-user-hero__actions .qa-btn--primary { background: #FFFFFF; color: #0F2A55; border-color: #FFFFFF; font-weight: 600; }

/* chips beside the name */
.qa-pro-chip, .qa-top-chip { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 6px; letter-spacing: .03em; }
.qa-pro-chip { color: #0F5132; background: #E3F5EA; }
.qa-top-chip { color: #6B3E00; background: #FFE9C2; }

/* the owner's panel on a free profile */
.qa-pro-unlock {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
    background: #FFFFFF;
    border: 1px solid #BFDBFE;
    border-left: 4px solid #1A5FD6;
    border-radius: 12px;
    padding: 14px 18px;
}
.qa-pro-unlock > div { display: flex; flex-direction: column; gap: 2px; flex: 1 1 380px; font-size: 14px; color: #334155; }
.qa-pro-unlock strong { color: #0F172A; font-size: 15px; }

@media (max-width: 640px) {
    .qa-user-page--v2 .qa-user-hero__banner { height: 100px; }
    .qa-user-page--v2 .qa-user-hero__top { padding: 0 18px; margin-top: -36px; }
    .qa-user-page--v2 .qa-user-hero__name-row { padding-top: 8px; }
    .qa-user-page--v2 .qa-user-hero__name { font-size: 24px; }
    .qa-user-page--v2 .qa-user-hero__info { padding: 12px 18px 0; }
}

/* ── The premium profile's own sections: services, work samples, phone ── */
.qa-pro { background: #FFFFFF; border: 1px solid #E2E8F0; border-radius: 12px; padding: 20px 22px; display: flex; flex-direction: column; gap: 20px; }
.qa-pro__title { margin: 0; font-size: 20px; color: #0F172A; }
.qa-pro__heading { margin: 0 0 8px; font-size: 15px; color: #334155; text-transform: uppercase; letter-spacing: .04em; }
.qa-pro__empty, .qa-pro__hint { margin: 0 0 10px; color: #64748B; font-size: 14px; }
.qa-pro__list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
/* A card is a column: picture (work samples), text, then the owner's Edit / Remove row at the bottom. overflow:hidden clips the full-width
   picture to the card's rounded top corners. */
.qa-pro__item { display: flex; flex-direction: column; border: 1px solid #E2E8F0; border-radius: 10px; padding: 12px 14px; background: #F8FAFC; overflow: hidden; }
/* The text grows to fill the card, so the Edit / Remove row lines up at the bottom of every card in a row, however long the text is. */
.qa-pro__item-body { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.qa-pro__item-body p { margin: 4px 0; color: #475569; font-size: 14px; }
.qa-pro__price { display: inline-block; font-size: 13px; font-weight: 600; color: #0F5132; background: #E3F5EA; border-radius: 6px; padding: 2px 8px; }
/* Work-sample pictures: one fixed shape (16:9) whatever the file, so the page does not jump while pictures load. */
/* Work sample picture: edge to edge across the top of the card. The negative margins cancel the card's padding (12px top, 14px sides), and the
   card's overflow:hidden gives it the card's rounded top corners. Fixed 16:9 shape, so the page does not jump while pictures load. */
.qa-pro__thumb { display: block; width: calc(100% + 28px); max-width: none; aspect-ratio: 16 / 9; object-fit: cover; margin: -12px -14px 10px; border-radius: 0; background: #E2E8F0; border-bottom: 1px solid #E2E8F0; }
.qa-pro__picture { display: grid; gap: 8px; }
.qa-pro__picture .qa-pro__hint { margin: 0; }
.qa-pro__preview { display: flex; align-items: flex-start; gap: 12px; }
.qa-pro__preview[hidden] { display: none; }
.qa-pro__preview img { width: 160px; max-width: 50%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; background: #E2E8F0; }
/* Long titles and texts: the title is cut to 2 lines and the text to 3, each ending in "...", so one long card does not stretch every card in
   its row. "Show more" (drawn only when something was cut) opens one card fully; .is-open removes both cuts. */
.qa-pro__name { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; }
.qa-pro__item-body .qa-pro__desc { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; line-clamp: 3; overflow: hidden; }
.qa-pro__item.is-open .qa-pro__name, .qa-pro__item.is-open .qa-pro__desc { display: block; -webkit-line-clamp: unset; line-clamp: none; overflow: visible; }
.qa-pro__more { display: block; margin: 0 0 6px; padding: 2px 0; background: none; border: 0; font: inherit; font-size: 13px; font-weight: 600; color: #1A5FD6; cursor: pointer; }
.qa-pro__more:hover { text-decoration: underline; }
.qa-pro__more[hidden] { display: none; }
/* The owner's Edit / Remove: one row at the bottom of the card, under a thin line, instead of stacked in the top-right corner. */
.qa-pro__item-actions { display: flex; flex-direction: row; align-items: center; gap: 20px; flex: none; margin-top: 12px; padding-top: 10px; border-top: 1px solid #E2E8F0; }
/* A little padding gives each link a larger area to tap. */
.qa-pro__link { background: none; border: 0; padding: 4px 0; font: inherit; font-size: 13px; font-weight: 600; color: #1A5FD6; cursor: pointer; }
.qa-pro__link:hover { text-decoration: underline; }
.qa-pro__link--danger { color: #B42318; }
.qa-pro__form { display: grid; gap: 10px; max-width: 560px; }
.qa-pro__form label { display: grid; gap: 4px; font-size: 13px; color: #475569; }
.qa-pro__form input[type=text], .qa-pro__form input[type=url], .qa-pro__form textarea { width: 100%; box-sizing: border-box; border: 1px solid #CBD5E1; border-radius: 8px; padding: 8px 10px; font: inherit; color: #0F172A; }
.qa-pro__form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.qa-pro__msg { font-size: 13px; color: #64748B; }
.qa-pro__msg.is-bad { color: #B42318; }
.qa-pro__msg.is-good { color: #0F5132; }
.qa-pro__check { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #0F172A; }
.qa-pro__phone a { font-size: 18px; font-weight: 600; color: #1A5FD6; text-decoration: none; }

@media (max-width: 640px) {
    .qa-pro { padding: 16px; }
    .qa-pro__list { grid-template-columns: 1fr; }
}

/* ── Inside the Profile tab ──
   The premium sections are drawn inside the Profile tab (above Education and Experience). The tab is already a white card, so a section
   there drops its own card border and is separated from the next part of the tab by a line instead (no card inside a card). */
.qa-user-posts > .qa-pro { border: 0; border-radius: 0; padding: 0 0 20px; margin: 0 0 20px; border-bottom: 1px solid #E2E8F0; }
/* Heading row: title block on the left, the visitor's "Request a quote" button on the right (it drops under the title on a narrow screen). */
.qa-pro__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.qa-pro__quote { flex: none; }
/* The quote section only carries the pop-up when its button sits in the heading row above; ".qa-pro { display: flex }" would beat [hidden]. */
section.qa-quote[hidden] { display: none; }
/* Title with the owner's one-line note under it. */
.qa-pro__intro { display: grid; gap: 4px; }
.qa-pro__intro .qa-pro__hint { margin: 0; }
/* "Services" / "Work samples" on the left, the owner's "+ Add ..." button on the right; the button drops under the heading on a narrow screen. */
.qa-pro__block-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; margin: 0 0 10px; }
.qa-pro__block-head .qa-pro__heading { margin: 0; }
.qa-pro__add { flex: none; }
/* Two short fields side by side in the pop-up (name and price, title and link); one under the other when there is no room. */
.qa-pro__row { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }

/* ── Request a quote and Enquiries ── */
.qa-quote__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.qa-quote__row { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.qa-quote .qa-pro__form select { width: 100%; box-sizing: border-box; border: 1px solid #CBD5E1; border-radius: 8px; padding: 8px 10px; font: inherit; background: #FFFFFF; color: #0F172A; }
.qa-quote .qa-pro__form input[type=email] { width: 100%; box-sizing: border-box; border: 1px solid #CBD5E1; border-radius: 8px; padding: 8px 10px; font: inherit; color: #0F172A; }
/* The form steps are shown and hidden with the "hidden" attribute. ".qa-pro__form { display: grid }" would otherwise beat it, which showed the
   "We sent a code to ." step on top of the form before any code was sent. */
.qa-pro__form[hidden], #qa-quote-done[hidden] { display: none; }

/* ── Pop-up window (modal) used by Request a quote ── */
.qa-modal[hidden] { display: none; }
.qa-modal { position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 16px; box-sizing: border-box; }
.qa-modal__backdrop { position: absolute; inset: 0; background: rgba(15, 23, 42, .55); }
.qa-modal__dialog { position: relative; width: 100%; max-width: 620px; max-height: calc(100vh - 32px); overflow-y: auto; background: #FFFFFF; border-radius: 14px; box-shadow: 0 20px 50px rgba(15, 23, 42, .3); outline: none; }
.qa-modal__head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; background: #FFFFFF; border-bottom: 1px solid #E2E8F0; }
.qa-modal__title { margin: 0; font-size: 18px; color: #0F172A; overflow-wrap: anywhere; }
.qa-modal__close { flex: none; width: 34px; height: 34px; border: 0; border-radius: 8px; background: transparent; color: #475569; font-size: 26px; line-height: 1; cursor: pointer; }
.qa-modal__close:hover { background: #F1F5F9; color: #0F172A; }
/* 15px inside the pop-up body (was 20px). */
.qa-modal__body { padding: 15px; display: grid; gap: 12px; }
.qa-modal__body .qa-pro__form { max-width: none; }
@media (max-width: 640px) {
    .qa-modal { align-items: flex-end; padding: 0; }
    .qa-modal__dialog { max-width: none; max-height: 92vh; border-radius: 14px 14px 0 0; }
}
.qa-quote__trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.qa-quote__ok { color: #0F5132; font-size: 18px; }
.qa-enq__count { font-size: 13px; font-weight: 600; color: #1A5FD6; background: #E7F0FD; border-radius: 999px; padding: 2px 10px; margin-left: 8px; vertical-align: middle; }
.qa-enq__list { grid-template-columns: 1fr; }
.qa-enq__item.is-new { border-left: 4px solid #1A5FD6; background: #F1F6FE; }
.qa-enq__when { margin-left: 8px; font-size: 12px; color: #64748B; }
