/* Lead forms and the "show phone" button (template-parts/lead-form.php, assets/js/forms.js). */

.ev-lead {
  padding: 24px;
  background: var(--ev-surface);
  border-radius: var(--ev-radius-md);
  color: var(--ev-ink);
}
.ev-lead--tint { background: var(--ev-bg); box-shadow: none; }
.ev-lead__form { display: grid; gap: 14px; }
.ev-lead__form[hidden], .ev-lead__done[hidden] { display: none; }
.ev-lead__title { margin: 0; font-size: 20px; font-weight: 700; line-height: 1.2; }
.ev-lead__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.ev-field { display: grid; gap: 6px; }
.ev-field__label {
  font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--ev-ink-3);
}
.ev-field__input {
  width: 100%; padding: 12px 14px;
  border: 1px solid var(--ev-line-strong); border-radius: var(--ev-radius-sm);
  background: var(--ev-surface); color: var(--ev-ink);
  font: 500 16px/1.4 var(--ev-font); /* 16px: no zoom on iOS */
  transition: border-color 0.15s;
}
.ev-field__input::placeholder { color: var(--ev-ink-4); }
.ev-field__input:hover { border-color: var(--ev-ink-3); }
textarea.ev-field__input { resize: vertical; min-height: 84px; }
.ev-field__input:focus-visible { outline: 2px solid var(--ev-ink); outline-offset: 1px; }
.ev-field__input[aria-invalid] { border-color: #b3261e; }
.ev-field__error { font-size: 13px; color: #b3261e; }
.ev-field__error:empty { display: none; }

.ev-check { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; color: var(--ev-ink-2); cursor: pointer; }
.ev-check input { flex: none; width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--ev-ink); }
.ev-check a { color: inherit; }

.ev-lead__captcha:empty { display: none; }
.ev-lead__submit { width: 100%; padding-block: 15px; gap: 8px; }
.ev-lead__submit .ev-icon { transition: transform 0.15s; }
.ev-lead__submit:hover .ev-icon { transform: translateX(3px); }
.ev-lead__submit:disabled { opacity: 0.6; cursor: progress; }
.ev-lead__status { margin: 0; font-size: 14px; color: var(--ev-ink-2); }
.ev-lead__status:empty { display: none; }
.ev-lead__done { display: grid; gap: 8px; }
.ev-lead__done p { margin: 0; }
.ev-lead__done:focus { outline: none; }

/* Property page aside: agent → phone → form */
.ev-property__aside { display: grid; gap: 14px; align-content: start; }
.ev-phone-btn { width: 100%; padding-block: 14px; background: var(--ev-surface); }
a.ev-phone-btn { font-size: 18px; font-weight: 700; text-decoration: none; }


/* Section promo (template-parts/section-promo.php): interior photo as a backdrop, everything readable in the card. */
.ev-main > .ev-promo, .ev-home > .ev-promo { margin-top: var(--ev-section-gap); }
.ev-promo__frame { position: relative; display: grid; border-radius: var(--ev-radius-lg); overflow: hidden; background: var(--ev-cypress-wash); }
.ev-promo__photo { display: block; width: 100%; height: 240px; object-fit: cover; }
.ev-promo__card {
  position: relative; display: grid; gap: 14px; margin: -48px 12px 12px; padding: 24px;
  background: var(--ev-surface); border-radius: var(--ev-radius-md); box-shadow: var(--ev-shadow-md);
}
.ev-promo__title { margin: 0; font-size: var(--ev-fs-title); line-height: 1.15; }
.ev-promo__lead { margin: 0; color: var(--ev-ink-2); line-height: 1.6; }
.ev-promo .ev-lead { padding: 0; }
.ev-promo__more { display: inline-flex; align-items: center; gap: 6px; color: var(--ev-ink); font-weight: 700; text-decoration: none; }
.ev-promo__more:hover { text-decoration: underline; }

/* Empty catalog result (template-parts/catalog-results.php): pitch + steps on the left, the tinted form on the right;
   on phones the form follows the text. */
.ev-empty--lead { display: grid; gap: 24px; }
.ev-empty__info > p { margin: 0 0 10px; }
.ev-empty__steps { display: grid; gap: 12px; margin: 20px 0 0; padding: 0; list-style: none; counter-reset: ev-step; }
.ev-empty__steps li { position: relative; padding-left: 44px; min-height: 30px; line-height: 1.5; counter-increment: ev-step; }
.ev-empty__steps li::before {
  content: counter(ev-step); position: absolute; left: 0; top: -2px;
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--ev-cypress-wash); color: var(--ev-cypress); font-weight: 700;
}
.ev-empty__info > .ev-empty__phone { margin: 20px 0 0; color: var(--ev-ink-2); }
.ev-empty__phone a { color: var(--ev-ink); font-weight: 700; }

@media (min-width: 1024px) {
  .ev-empty--lead { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; padding: 40px; }
  .ev-empty__info { align-self: center; max-width: 480px; }
  .ev-empty--lead .ev-empty__title { margin-bottom: 14px; font-size: 25px; line-height: 1.2; }
}

@media (min-width: 768px) {
  .ev-promo__photo { height: 320px; }
  .ev-promo__card { margin: -80px 32px 32px; padding: 32px; }
}
@media (min-width: 1024px) {
  .ev-promo__frame { min-height: 620px; align-items: center; }
  .ev-promo__photo { position: absolute; inset: 0; height: 100%; }
  .ev-promo__card { width: min(480px, 44%); margin: 56px; padding: 36px; }
}

/* Star rating (template-parts/review-form.php): radios 1…5, each followed by its star label. Stars up to the checked
   one are ink (:has), the ones after it grey; hover previews the same way. Ink, not yellow: the yellow is for buttons. */
.ev-rating { border: 0; margin: 0; padding: 0; min-width: 0; }
.ev-rating__stars { display: inline-flex; justify-self: start; gap: 4px; }
.ev-rating__input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ev-rating__star { display: inline-flex; padding: 2px; color: var(--ev-line-strong); cursor: pointer; transition: color 0.1s; }
.ev-rating__star .ev-icon { fill: currentColor; stroke-width: 1; }
.ev-rating__stars:has(.ev-rating__input:checked) .ev-rating__star,
.ev-rating__stars:hover .ev-rating__star { color: var(--ev-ink); }
.ev-rating__input:checked + .ev-rating__star ~ .ev-rating__star,
.ev-rating__stars:hover .ev-rating__star:hover ~ .ev-rating__star { color: var(--ev-line-strong); }
.ev-rating__input:focus-visible + .ev-rating__star { outline: 2px solid var(--ev-ink); outline-offset: 2px; border-radius: 4px; }

/* Request block (template-parts/lead-block.php; contacts reuse the inner card): white card, text on the left, the
   tinted form on the right. */
.ev-leadblock__inner {
  display: grid; gap: 24px; align-items: center;
  padding: 28px 22px; background: var(--ev-surface); border-radius: var(--ev-radius-xl);
}
.ev-leadblock__title { margin: 6px 0 0; }
.ev-leadblock__lead { max-width: 560px; margin: 14px 0 0; color: var(--ev-ink-2); line-height: 1.6; }
.ev-leadblock__points { display: grid; gap: 10px; margin: 20px 0 0; padding: 0; list-style: none; font-weight: 600; }
.ev-leadblock__points li { display: flex; align-items: center; gap: 10px; }
.ev-leadblock__points .ev-icon { flex: none; color: var(--ev-cypress); }
.ev-leadblock__link { display: inline-flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--ev-ink); font-weight: 700; }
@media (min-width: 1024px) {
  .ev-leadblock__inner { grid-template-columns: 1.4fr 1fr; gap: 60px; padding: 56px; }
}

/* «Стежити за пошуком» (template-parts/subscribe-form.php): a white bar above the catalog cards that opens the form. */
.ev-subscribe { margin: 0 0 18px; background: var(--ev-surface); border-radius: var(--ev-radius-md); }
.ev-subscribe__bar {
  display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 10px 14px; padding: 14px 18px;
  cursor: pointer; list-style: none;
}
.ev-subscribe__bar::-webkit-details-marker { display: none; }
.ev-subscribe__bar:focus-visible { outline: 2px solid var(--ev-ink); outline-offset: 2px; border-radius: var(--ev-radius-md); }
.ev-subscribe__icon {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--ev-cypress-wash); color: var(--ev-cypress);
}
.ev-subscribe__text { display: grid; gap: 2px; font-size: 14px; }
.ev-subscribe__text span { color: var(--ev-ink-3); font-size: 13px; }
.ev-subscribe__open { grid-column: 1 / -1; justify-self: start; pointer-events: none; }
.ev-subscribe[open] .ev-subscribe__open { display: none; }
.ev-subscribe__body { padding: 0 18px 18px; }
.ev-subscribe__form { max-width: 640px; }
.ev-subscribe__row { display: grid; gap: 10px; }
.ev-subscribe__submit { padding-block: 13px; }
@media (min-width: 768px) {
  .ev-subscribe__bar { grid-template-columns: auto 1fr auto; }
  .ev-subscribe__open { grid-column: auto; }
  .ev-subscribe__row { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
}

/* Subscription page /pidpyska/ (subscription.php) */
.ev-subpage__card {
  max-width: 640px; margin: 24px 0; padding: 28px 24px; background: var(--ev-surface); border-radius: var(--ev-radius-lg);
}
.ev-subpage__title { margin: 0 0 14px; font-size: var(--ev-fs-title); line-height: 1.15; }
.ev-subpage__card p { margin: 0 0 12px; line-height: 1.6; }
.ev-subpage__search a {
  display: block; padding: 14px 16px; border-radius: var(--ev-radius-sm); background: var(--ev-bg);
  color: var(--ev-ink); font-weight: 600; text-decoration: none;
}
.ev-subpage__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }

/* Valuation page (template-valuation.php, assets/js/valuation.js): the object form, then the range and the lead form. */
.ev-valuation__card { padding: 24px; background: var(--ev-surface); border-radius: var(--ev-radius-md); }
.ev-valuation__grid { display: grid; gap: 14px; }
.ev-valuation__grid [hidden] { display: none; }
.ev-valuation__group { margin: 8px 0 0; font-size: 20px; font-weight: 700; }
.ev-valuation__hint { margin: 0; font-size: 13px; color: var(--ev-ink-3); }
.ev-valuation__submit { justify-self: start; }
select.ev-field__input {
  appearance: none; padding-right: 36px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--ev-ink-3) 50%), linear-gradient(135deg, var(--ev-ink-3) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px; background-repeat: no-repeat;
}
.ev-main > .ev-valuation__head + .ev-section { margin-top: 32px; }
.ev-valuation__grid .ev-field { align-content: start; }
.ev-valuation__result { display: grid; gap: 24px; scroll-margin-top: 120px; }
.ev-valuation__result[hidden] { display: none; }
.ev-valuation__price { margin: 6px 0 0; font-size: var(--ev-fs-title); font-weight: 700; line-height: 1.15; }
.ev-valuation__basis { margin: 8px 0 0; color: var(--ev-ink-2); }
.ev-valuation__note {
  margin: 16px 0 0; padding: 14px 16px; border-radius: var(--ev-radius-sm);
  background: var(--ev-cypress-wash); line-height: 1.5;
}
.ev-valuation__back {
  justify-self: start; padding: 0; border: 0; background: none; color: var(--ev-ink);
  font: 700 16px/1.4 var(--ev-font); text-decoration: underline; cursor: pointer;
}
.ev-valuation__back[hidden] { display: none; }
@media (min-width: 768px) {
  .ev-valuation__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 20px; }
  .ev-valuation__wide { grid-column: 1 / -1; }
}
@media (min-width: 1024px) {
  .ev-valuation__card { padding: 40px; }
  .ev-valuation__result { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; }
}
