/*
Theme Name:   ExpertHive Child
Theme URI:    https://juanworks.ph
Description:  A custom child theme for the Juan Works marketplace.
Author:       Aeros Salaga
Author URI:   https://aerossalaga.com
Template:     experthive
Version:      1.0.0
Text Domain:  experthive-child
*/

/* Listing offers – align icon + text and use muted link color. */
.hp-requests .hp-listing__action--offer {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	color: rgba(15, 23, 39, 0.6);
	text-decoration: none;
}

.hp-listing__action--offer .hp-listing__action-label {
	color: rgba(15, 23, 39, 0.6);
}

.hp-listing__action--offer .hp-icon {
	color: rgba(15, 23, 39, 0.6);
}

.hp-listing__action--offer-submitted .hp-listing__action-label {
	font-style: italic;
}

/* JuanWorker account settings – Qualifications/Certificates. */
.juanworks-qualifications__item {
	display: grid;
	grid-template-columns: 1fr 1fr auto;
	gap: 1rem;
	align-items: end;
	margin: 0 0 1rem;
}

.juanworks-qualifications__image-actions {
	display: flex;
	gap: 0.5rem;
	flex-wrap: wrap;
}

.juanworks-qualifications__add {
	margin-top: 0.5rem;
}

.juanworks-qualifications__image-preview {
	margin-bottom: 0.5rem;
}

/* JuanWorker public profile – Qualifications/Certificates. */
.juanworks-vendor-qualifications__list {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1rem;
	margin-top: 1rem;
}

.juanworks-vendor-qualifications__item {
	display: flex;
    align-items: center;
    gap: 0.75rem;
    text-align: center;
    flex-direction: column;
}

.juanworks-vendor-qualifications__image img {
	border-radius: 4px;
	display: block;
}

/* Request sidebar vendor block – add label to message icon. */
.hp-vendor--view-block .juanworks-vendor-message-action {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
}

.hp-vendor--view-block .juanworks-vendor-message-label {
	font-weight: 500;
}

/* Qualification lightbox. */
.juanworks-qualification__link {
	display: inline-block;
}

.juanworks-qualification__link img {
	cursor: zoom-in;
}

.juanworks-lightbox {
	position: fixed;
	inset: 0;
	z-index: 9999;
	background: rgba(0, 0, 0, 0.75);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1.5rem;
}

.juanworks-lightbox__inner {
	position: relative;
	max-width: min(960px, 100%);
	max-height: 100%;
}

.juanworks-lightbox__image {
	max-width: 100%;
	max-height: 85vh;
	display: block;
	border-radius: 4px;
}

/* Homepage hero: full-width background video (if attached). */
.header-hero.juanworks-hero--video {
	position: relative;
	overflow: hidden;
}

.header-hero.juanworks-hero--video .juanworks-hero__video {
	position: absolute;
	inset: 0;
	z-index: 0;
	pointer-events: none;
}

.header-hero.juanworks-hero--video .juanworks-hero__video-el {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.header-hero.juanworks-hero--video .juanworks-hero__youtube {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	/*
		This sizing ensures the iframe always covers the hero like `object-fit: cover`.
		16:9 video -> use viewport-min trick so it overflows and covers.
	*/
	width: max(100vw, calc(100vh * 1.78));
	height: max(100vh, calc(100vw / 1.78));
	border: 0;
	pointer-events: none;
}

.header-hero.juanworks-hero--video .header-hero__content {
	position: relative;
	z-index: 1;
}

/* Optional: remove the image column on the homepage hero when video is present. */
.header-hero.juanworks-hero--video .header-hero__images,
.header-hero.juanworks-hero--video .header-hero__column:nth-child(2) {
	display: none;
}

.header-hero.juanworks-hero--video .header-hero__column {
	width: 100%;
}

/* Disabled "Job is no longer available" action button. */
.juanworks-offer-unavailable {
	opacity: 0.65;
	cursor: not-allowed;
}

/* Rate worker popup (shown after Job Complete). */
.juanworks-rate-worker .juanworks-lightbox__inner {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
	padding: 1.25rem 1.25rem 1rem;
	width: min(520px, 100%);
}

.juanworks-rate-worker__content h3 {
	margin: 0 0 0.75rem;
	font-size: 1.125rem;
}

.juanworks-rate-worker__stars {
	display: flex;
	gap: 0.5rem;
	margin: 0 0 0.75rem;
}

.juanworks-rate-worker__stars button {
	border: 0;
	background: transparent;
	cursor: pointer;
	padding: 0;
	line-height: 1;
	font-size: 1.5rem;
	color: #f5b301; /* star color */
}

.juanworks-rate-worker__stars button:focus {
	outline: 2px solid rgba(0, 135, 111, 0.35);
	outline-offset: 2px;
	border-radius: 4px;
}

.juanworks-rate-worker__text {
	width: 100%;
	box-sizing: border-box;
	border: 1px solid rgba(15, 23, 39, 0.2);
	border-radius: 6px;
	padding: 0.75rem;
	margin: 0 0 0.75rem;
}

.juanworks-rate-worker [data-juanworks-submit] {
	width: 100%;
}

/* Worker plan chooser popup (post-registration). */
.juanworks-plan-popup .juanworks-lightbox__inner {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
	padding: 1.25rem;
	width: min(760px, 100%);
}

.juanworks-plan-popup__content h3 {
	margin: 0 0 0.5rem;
	font-size: 1.125rem;
}

.juanworks-plan-popup__content > p {
	margin: 0 0 1rem;
	color: rgba(15, 23, 39, 0.75);
}

.juanworks-plan-popup__options {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1rem;
}

.juanworks-plan-popup__card {
	border: 1px solid rgba(15, 23, 39, 0.15);
	border-radius: 8px;
	padding: 1rem;
	background: #fff;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

.juanworks-plan-popup__card h4 {
	margin: 0;
	font-size: 1rem;
}

.juanworks-plan-popup__card p {
	margin: 0;
	color: rgba(15, 23, 39, 0.75);
}

.juanworks-plan-popup__card .button {
	margin-top: auto;
}

.juanworks-plan-popup__card.is-active {
	border-color: #00876f;
	box-shadow: 0 0 0 1px rgba(0, 135, 111, 0.2) inset;
}

.juanworks-plan-popup__card.is-disabled {
	opacity: 0.7;
}

/* Job unavailable popup. */
.juanworks-job-unavailable .juanworks-lightbox__inner {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
	padding: 1.25rem;
	width: min(460px, 100%);
}

.juanworks-job-unavailable__content {
	text-align: center;
}

.juanworks-job-unavailable__message {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
	color: rgba(15, 23, 39, 0.92);
}

.juanworks-lightbox__close {
	position: absolute;
	top: 0.5rem;
	right: 0.5rem;
	width: 2.5rem;
	height: 2.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.5rem;
	line-height: 1;
	padding: 0;
}

/* Notifications. */
.juanworks-notifications__list {
	list-style: none;
	padding: 0;
	margin: 1rem 0 0;
}

.juanworks-notifications__item {
	border-radius: 4px;
	padding: 0.75rem 0.75rem;
}

.juanworks-notifications__item.is-unread {
	box-shadow: 0 5px 30px rgba(7, 36, 86, 0.075);
	background: #fff;
}

.juanworks-notifications__link {
	display: flex;
	justify-content: space-between;
	gap: 1rem;
	text-decoration: none;
	color: inherit;
}

.juanworks-notifications__time {
	white-space: nowrap;
	font-size: 0.8125rem;
	opacity: 0.7;
}

.juanworks-notifications-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 1.25rem;
	height: 1.25rem;
	padding: 0 0.35rem;
	border-radius: 9999px;
	background: #00876F;
	color: #fff;
	font-size: 0.75rem;
	font-weight: 700;
	line-height: 1;
}

/* JuanWorker ratings on cards and profile page. */
.juanworks-worker-rating-summary {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	margin-top: 0.5rem;
	font-size: 0.875rem;
}

.juanworks-worker-rating-summary__score {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	font-weight: 600;
}

.juanworks-worker-rating-summary__score .hp-icon {
	color: #f5b301;
}

.juanworks-worker-rating-summary__count,
.juanworks-worker-rating-summary__empty {
	color: rgba(15, 23, 39, 0.7);
}

.juanworks-worker-rating-inline {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	margin-left: 0.5rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: rgba(15, 23, 39, 0.85);
}

.juanworks-worker-rating-inline .hp-icon {
	color: #f5b301;
}

.juanworks-worker-rating-inline--under-name {
	display: flex;
	justify-content: center;
	width: 100%;
	margin-left: 0;
	margin-top: 0.35rem;
}

.juanworks-offer-worker-rating {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	margin-left: 0.5rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: rgba(15, 23, 39, 0.85);
}

.juanworks-offer-worker-rating .hp-icon {
	color: #f5b301;
}

.juanworks-offer-worker-rating--under-name {
	display: flex;
	width: 100%;
	margin-left: 0;
	margin-top: 0.35rem;
}

.hp-vendor--view-block .juanworks-verified-badge,
.hp-vendor--view-page .juanworks-verified-badge {
	position: static;
	top: auto;
	right: auto;
	margin: 0;
}

.juanworks-verified-badge {
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	color: #1877f2;
	font-size: 0.8125rem;
	font-weight: 600;
}

.juanworks-verified-badge .hp-icon {
	color: #1877f2;
}

.juanworks-verified-badge--inline {
	margin-left: 0;
	vertical-align: top;
	font-size: 0.6875rem;
	line-height: 1;
}

.juanworks-verified-badge--inline .hp-icon {
	font-size: 1.15rem;
}

.juanworks-verified-badge--profile {
	display: inline-flex;
	margin-left: 0;
	margin-top: 0.35rem;
}

.juanworks-vendor-name-wrap {
	position: relative;
	display: inline-block;
	padding-right: 0.9rem;
}

.juanworks-vendor-name-wrap .juanworks-verified-badge--inline {
	position: absolute;
	right: -6px;
}

.juanworks-vendor-reviews-sidebar {
	margin-top: 0.75rem;
	padding-top: 0.75rem;
	border-top: 1px solid rgba(15, 23, 39, 0.12);
}

.juanworks-vendor-reviews-sidebar__score {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	font-size: 0.95rem;
}

.juanworks-vendor-reviews-sidebar__score .hp-icon {
	color: #f5b301;
}

.juanworks-vendor-reviews-sidebar__count {
	margin-top: 0.35rem;
	margin-bottom: 0.6rem;
	color: rgba(15, 23, 39, 0.7);
	font-size: 0.85rem;
}

.juanworks-vendor-reviews-popup[hidden] {
	display: none;
}

.juanworks-vendor-reviews-popup .juanworks-lightbox__inner {
	background: #fff;
	border-radius: 8px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
	padding: 1.1rem;
	width: min(760px, 100%);
	max-height: 88vh;
	overflow: auto;
}

.juanworks-vendor-reviews {
	margin-top: 1.5rem;
}

.juanworks-vendor-reviews__title {
	margin: 0 0 0.5rem;
}

.juanworks-vendor-reviews__average {
	margin: 0 0 1rem;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
}

.juanworks-vendor-reviews__list {
	list-style: none;
	padding: 0;
	margin: 0;
	display: grid;
	gap: 0.75rem;
}

.juanworks-vendor-reviews__item {
	border: 1px solid rgba(15, 23, 39, 0.15);
	border-radius: 8px;
	padding: 0.75rem;
	background: #fff;
}

.juanworks-vendor-reviews__item-head {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 0.35rem;
}

.juanworks-vendor-reviews__item-rating {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	font-weight: 600;
}

.juanworks-vendor-reviews__item-rating .hp-icon {
	color: #f5b301;
}

.juanworks-vendor-reviews__item-owner,
.juanworks-vendor-reviews__item-date {
	color: rgba(15, 23, 39, 0.65);
	font-size: 0.875rem;
}

.juanworks-vendor-reviews__item-text,
.juanworks-vendor-reviews__empty {
	margin: 0;
	color: rgba(15, 23, 39, 0.85);
}

.hp-offer.juanworks-offer--flash {
	background-color: #fff8cf;
	box-shadow: inset 0 0 0 1px rgba(245, 179, 1, 0.35);
	transition: background-color 2.2s ease, box-shadow 2.2s ease;
}

.hp-offer.juanworks-offer--flash.juanworks-offer--flash-active {
	background-color: transparent;
	box-shadow: inset 0 0 0 1px rgba(245, 179, 1, 0);
}

@media (prefers-reduced-motion: reduce) {
	.hp-offer.juanworks-offer--flash {
		transition: none;
	}
}

.juanworks-verification__status,
.juanworks-verification__help {
	margin-bottom: 0.75rem;
}

.juanworks-verification__form .hp-field {
	margin-bottom: 0.75rem;
}

.juanworks-verification__files {
	margin: 0 0 0.75rem;
	font-size: 0.9rem;
	color: rgba(15, 23, 39, 0.75);
}

@media (max-width: 767px) {
	.juanworks-qualifications__item {
		grid-template-columns: 1fr;
	}

	.juanworks-plan-popup__options {
		grid-template-columns: 1fr;
	}

	.hp-listing--view-block .hp-listing__footer {
        flex-wrap: wrap;
    }
}


