/*
 Theme Name: ekotheme
 Theme URI: https://plan-b-immobilien.me
 Description: Integriertes Child-Theme für Hello Elementor mit originalgetreuem Plan-B-Header, Footer, Floating Bottom Navigation und Last-Updated-/Autor-Modul.
 Author: Ekrem Rexhepagaj
 Author URI: https://ekosphere.me
 Template: hello-elementor
 Version: 1.1.3
 Text Domain: ekotheme
*/

/* Shared content layout for the ekosphere test migration. */
body.wp-singular main#content.site-main {width:min(calc(100% - 2 * clamp(1rem,4vw,3rem)),1180px)!important;max-width:1180px!important;margin-inline:auto!important;padding-block:clamp(1.75rem,4vw,4rem) 4rem;color:#193037;}
body.wp-singular main#content.site-main .page-content {min-width:0;font-size:clamp(1rem,.94rem + .24vw,1.16rem);line-height:1.7;overflow-wrap:anywhere;}
body.wp-singular main#content.site-main .page-content > section {margin-block:0 clamp(2rem,5vw,4.75rem);}
body.wp-singular main#content.site-main .page-content > section > :is(p,ul,ol) {max-width:none;}
body.wp-singular main#content.site-main .page-content :is(h1,h2,h3) {color:#12343a;line-height:1.17;text-wrap:balance;}
body.wp-singular main#content.site-main .page-content h1 {font-size:clamp(1.65rem,2.5vw,2.5rem);letter-spacing:-.035em;margin:0 0 1rem;}
body.wp-singular main#content.site-main .page-content h2 {font-size:clamp(1.65rem,2.65vw,2.65rem);letter-spacing:-.022em;margin:0 0 .7rem;}
body.wp-singular main#content.site-main .page-content h3 {font-size:clamp(1.14rem,1.55vw,1.46rem);margin:0 0 .5rem;}
body.wp-singular main#content.site-main:has(.page-content > section[aria-labelledby="ek-hero-title"] h1) > .page-header:not(:focus-within) {display:none;}
body.wp-singular main#content.site-main .page-content figure {margin:0;}
body.wp-singular main#content.site-main .page-content figure img {display:block;max-width:100%;height:auto;border-radius:2px;}
body.wp-singular main#content.site-main .page-content > figure:first-child {margin-bottom:clamp(1.25rem,3vw,2.5rem);}
body.wp-singular main#content.site-main .page-content > figure:first-child > img {width:100%;aspect-ratio:16/9;object-fit:cover;}
body.wp-singular main#content.site-main .page-content > section[aria-labelledby="ek-hero-title"] > a[href] {display:inline-flex;align-items:center;margin:.45rem .55rem .25rem 0;padding:.65rem .95rem;border:1px solid #0b635f;border-radius:.4rem;color:#0b5957;font-weight:650;text-decoration:none;}
body.wp-singular main#content.site-main .page-content > section[aria-labelledby="ek-hero-title"] > a[href]:first-of-type {background:#0b635f;color:#fff;}
body.wp-singular main#content.site-main .page-content > section:has(> nav) > nav {padding:clamp(1rem,3vw,1.8rem);background:#f1f6f5;border-radius:.75rem;border:1px solid #dbe8e5;}
body.wp-singular main#content.site-main .page-content > section:has(> article + article) {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:clamp(.9rem,2vw,1.5rem);align-items:stretch;}
body.wp-singular main#content.site-main .page-content > section:has(> article + article) > :not(article) {grid-column:1/-1;margin-block:0;}
body.wp-singular main#content.site-main .page-content > section:has(> article + article) > article {min-width:0;background:#f6f9f8;border:1px solid #dce8e5;border-radius:2px;padding:clamp(1rem,2.5vw,1.65rem);}
body.wp-singular main#content.site-main .page-content > section:has(> article + article) > article > :last-child {margin-bottom:0;}
body.wp-singular main#content.site-main .page-content > section > details {border-bottom:1px solid #dce8e5;padding:.65rem .1rem;}
body.wp-singular main#content.site-main .page-content > section > details > summary {cursor:pointer;font-weight:650;}
body.wp-singular main#content.site-main .page-content :is(a,summary):focus-visible {outline:2px solid #0b635f;outline-offset:3px;}
@media(min-width:1000px) {
  body.home main#content.site-main .page-content:has(> figure:first-child + section[aria-labelledby="ek-hero-title"]) {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:clamp(1.4rem,4vw,3rem);align-items:center;}
  body.home main#content.site-main .page-content:has(> figure:first-child + section[aria-labelledby="ek-hero-title"]) > * {grid-column:1/-1;}
  body.home main#content.site-main .page-content > figure:first-child:has(+ section[aria-labelledby="ek-hero-title"]) {grid-column:2;grid-row:1;margin-bottom:3rem;}
  body.home main#content.site-main .page-content > figure:first-child + section[aria-labelledby="ek-hero-title"] {grid-column:1;grid-row:1;margin-bottom:3rem;}
  body.wp-singular main#content.site-main .page-content > section[aria-labelledby="ek-three-areas"]:has(> article + article) {grid-template-columns:repeat(3,minmax(0,1fr));}
}
@media(max-width:640px) {body.wp-singular main#content.site-main .page-content > section:has(> article + article) {grid-template-columns:minmax(0,1fr);}}

/* Compact edges, consistent shadows and a connected hero and table of contents. */
:root {--ekosphere-surface-shadow:0 2px 7px #122e3920;--ekosphere-hover-shadow:0 7px 18px #122e3935;}
body.wp-singular main#content.site-main :is(img,article,.ek-card,.ekds-lp-card,.ekds-lp-tile,.ekds-lp-review,.ek-tile),
body :is(a.button,a.wp-element-button,a.elementor-button,a[class*="cta"],.wp-block-button__link,.ekds-lp-btn,.ek-button,.planb-nav__link--cta,button[type="submit"]),
body.wp-singular main#content.site-main section[aria-labelledby="ek-hero-title"] > a[href] {border-radius:2px!important;box-shadow:none!important;transition:box-shadow .2s ease;}
body.wp-singular main#content.site-main :is(img,article,.ek-card,.ekds-lp-card,.ekds-lp-tile,.ekds-lp-review,.ek-tile):is(:hover,:focus-within),
body :is(a.button,a.wp-element-button,a.elementor-button,a[class*="cta"],.wp-block-button__link,.ekds-lp-btn,.ek-button,.planb-nav__link--cta,button[type="submit"]):is(:hover,:focus-visible),
body.wp-singular main#content.site-main section[aria-labelledby="ek-hero-title"] > a[href]:is(:hover,:focus-visible) {box-shadow:none!important;}
body.wp-singular main#content.site-main .page-content > :is(section[aria-labelledby="ek-hero-title"],figure:first-child:has(+section[aria-labelledby="ek-hero-title"])) {margin-bottom:0;}
body.wp-singular main#content.site-main .page-content > section[aria-labelledby="ek-hero-title"] + section:has(> nav) {margin-top:0;}
body.wp-singular main#content.site-main .page-content > section[aria-labelledby="ek-hero-title"] + section > nav {border-top:2px solid #0b635f;border-radius:0 0 2px 2px;}
body.wp-singular main#content.site-main .page-content > section > article > .ekosphere-card-image {display:block;width:100%;height:auto;aspect-ratio:16/9;object-fit:cover;margin:0 0 1rem;}
@media(prefers-reduced-motion:reduce){body.wp-singular main#content.site-main :is(img,article,a),body button[type="submit"]{transition:none;}}

/* WhatsApp actions follow the compact, dark-green button reference. */
body:not(.wp-admin) main#content#content a:is(.ek-wa-cta,[href^="https://wa.me/"],[href^="https://api.whatsapp.com/"],[href^="https://web.whatsapp.com/"]) {display:inline-flex!important;align-items:center!important;justify-content:center!important;justify-self:start!important;vertical-align:middle;gap:8px!important;box-sizing:border-box;width:fit-content!important;min-width:min(100%,264px)!important;max-width:100%!important;min-height:51px!important;margin:6px 12px 6px 0!important;padding:10px 20px!important;background:#195b3d!important;color:#fff!important;border:1px solid #195b3d!important;border-radius:2px!important;font-size:16px!important;font-weight:700!important;line-height:1.35!important;text-align:center!important;text-decoration:none!important;white-space:normal!important;box-shadow:none!important;}
body:not(.wp-admin) main#content#content a:is(.ek-wa-cta,[href^="https://wa.me/"],[href^="https://api.whatsapp.com/"],[href^="https://web.whatsapp.com/"]):is(:hover,:focus-visible) {background:#10452d!important;border-color:#10452d!important;color:#fff!important;box-shadow:none!important;}
body:not(.wp-admin) main#content#content a:is(.ek-wa-cta,[href^="https://wa.me/"],[href^="https://api.whatsapp.com/"],[href^="https://web.whatsapp.com/"]) :is(span,strong) {color:inherit!important;}
body:not(.wp-admin) main#content#content a:is(.ek-wa-cta,[href^="https://wa.me/"],[href^="https://api.whatsapp.com/"],[href^="https://web.whatsapp.com/"]) img {width:21px!important;height:21px!important;flex:0 0 21px;object-fit:contain;box-shadow:none!important;}
body:not(.wp-admin) main#content#content li > a:is(.ek-wa-cta,[href^="https://wa.me/"],[href^="https://api.whatsapp.com/"]) {display:inline-flex!important;min-width:0!important;min-height:0!important;margin:0!important;padding:0!important;background:transparent!important;border:0!important;box-shadow:none!important;color:#195b3d!important;font-size:inherit!important;text-decoration:underline!important;text-align:start!important;}

/* Estate-inspired layout for DS team profiles. */
body.wp-singular main#content.site-main .ekosphere-about-team {width:100%;max-width:none;margin-inline:0;padding-top:clamp(1.4rem,3vw,2.4rem);}
body.wp-singular main#content.site-main .ekosphere-about-team > h2 {font-size:clamp(1.65rem,3vw,2.25rem)!important;text-align:center;margin-bottom:1.6rem;}
.ekosphere-profile-grid {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:24px;margin-top:24px;}
.ekosphere-profile-card {display:block;min-width:0;padding:0;overflow:hidden;background:#fff;border:1px solid #775b48;}
body.wp-singular main#content.site-main .ekosphere-profile-photo img {display:block;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;object-position:center 28%;}
.ekosphere-profile-copy {padding:24px;}
body.wp-singular main#content.site-main .ekosphere-profile-copy h3 {font-size:20px!important;text-align:center;margin:0 0 .6rem;}
body.wp-singular main#content.site-main .ekosphere-profile-copy p {margin:0 0 .65rem;text-align:start;line-height:1.65;}
body.wp-singular main#content.site-main .ekosphere-profile-copy .ekosphere-profile-role {color:#705b4d;font-weight:700;font-size:16px;}
.ekosphere-profile-copy :last-child {margin-bottom:0;}
@media(max-width:760px){.ekosphere-profile-grid{grid-template-columns:minmax(0,1fr);}.ekosphere-profile-copy{padding:18px;}}

/* Estate table-of-contents dimensions and presentation. */
body.wp-singular main#content.site-main .page-content > section:has(> nav[aria-labelledby="ek-toc-title"]) {width:100%;margin-inline:0;}
body.wp-singular main#content.site-main .page-content > section > nav[aria-labelledby="ek-toc-title"] {width:100%;margin:0;padding:0;border:0;border-radius:0;background:transparent;color:#2a211b;font:400 20px/33px Roboto,system-ui,-apple-system,"Segoe UI",Arial,sans-serif;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] > details {margin:0;padding:0;border:1px solid #d4c2a8;border-radius:0;background:#f3e8d8;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] summary {display:list-item;margin:0;padding:12px 16px;border:0;border-radius:0;background:#5a3e2b;color:#fff;font:inherit;cursor:pointer;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] summary::marker {content:"";}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] summary::-webkit-details-marker {display:none;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] :is(details[open] > summary,summary:hover,summary:focus-visible) {background:#3a281d;color:#fff;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] ol {margin:0;padding:12px 16px 26px 48px;font:inherit;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] li {margin:0 0 5.6px;padding:0;color:#2a211b;font:inherit;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] a {display:block;color:#2a211b;font:inherit;text-decoration:none;}
body.wp-singular main#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] a:is(:hover,:focus-visible) {text-decoration:underline;}

/* Flush TOC and matching contact action dimensions. */
body.wp-singular main#content.site-main .page-content > section:has(> nav[aria-labelledby="ek-toc-title"]) {width:100%;margin-inline:0;}
body.wp-singular main#content.site-main .page-content > figure:first-child:has(+ section > nav[aria-labelledby="ek-toc-title"]) {margin-bottom:0;}
body.wp-singular main#content.site-main .page-content > figure:first-child + section:has(> nav[aria-labelledby="ek-toc-title"]) {margin-block:0 1.35rem;}
body:not(.wp-admin) main#content#content a[href].ekosphere-contact-form-cta {display:inline-flex!important;align-items:center!important;justify-content:center!important;justify-self:start!important;vertical-align:middle;box-sizing:border-box;width:fit-content!important;max-width:100%!important;min-height:51px!important;margin:6px 12px 6px 0!important;padding:10px 20px!important;background:#fff!important;color:#195b3d!important;border:1px solid #195b3d!important;border-radius:2px!important;font-size:16px!important;font-weight:700!important;line-height:1.35!important;text-align:center!important;text-decoration:none!important;box-shadow:none!important;}
body:not(.wp-admin) main#content#content a[href].ekosphere-contact-form-cta:is(:hover,:focus-visible) {background:#edf6f1!important;box-shadow:none!important;}

/* Balanced spacing around content and card titles. */
body.wp-singular main#content.site-main {--ekosphere-title-space:clamp(1.125rem,2.2vw,1.75rem);--ekosphere-card-title-space:clamp(.75rem,1.45vw,1rem);}
body.wp-singular main#content#content.site-main :is(.page-content,.page-header) :is(h1,h2,h3,h4,h5,h6) {margin-block:var(--ekosphere-title-space)!important;}
body.wp-singular main#content#content.site-main .page-content :is(article,.ek-card,.ekds-lp-card,.ekds-lp-tile,.ek-tile) :is(h1,h2,h3,h4,h5,h6) {margin-block:var(--ekosphere-card-title-space)!important;}

/* Paired contact actions: one row on wide screens, matching stacked buttons on mobile. */
body:not(.wp-admin) main#content#content .ekosphere-cta-pair {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch;gap:24px;grid-column:1/-1;width:min(100%,42rem);margin-block:36px 12px;}
body:not(.wp-admin) main#content#content .ekosphere-cta-pair > a[href] {justify-self:stretch!important;width:100%!important;min-width:0!important;max-width:none!important;min-height:51px!important;margin:0!important;overflow-wrap:anywhere;}
@media (max-width:760px) {body:not(.wp-admin) main#content#content .ekosphere-cta-pair {grid-template-columns:minmax(0,1fr);width:100%;gap:14px;margin-block-start:24px;}}

/* Only bordered cards cast a shadow. */
body.wp-singular main#content#content.site-main .page-content :is(section:has(> article + article) > article,.ekosphere-profile-card) {box-shadow:var(--ekosphere-surface-shadow)!important;}
body.wp-singular main#content#content.site-main .page-content :is(section:has(> article + article) > article,.ekosphere-profile-card):is(:hover,:focus-within) {box-shadow:var(--ekosphere-hover-shadow)!important;}

/* Align final actions across cards in each desktop row. */
@media (min-width:761px) {
  body.wp-singular main#content#content.site-main .page-content section:has(> article + article) > article:has(> :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child) {display:flex;flex-direction:column;}
  body.wp-singular main#content#content.site-main .page-content section:has(> article + article) > article > :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child {align-self:center;justify-content:center;margin-block:auto 0!important;margin-inline:auto!important;}
  body.wp-singular main#content#content.site-main .page-content section:has(> article + article) > article > :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child::before {flex-shrink:0;}
  body.wp-singular main#content#content.site-main .page-content section:has(> article + article) > article > :has(+ :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child) {margin-bottom:1.25rem;}
}

/* Shared vertical tracks for cards with the same content structure. */
@supports (grid-template-rows:subgrid) {
  @media (min-width:761px) {
    body.wp-singular main#content#content.site-main .page-content section[aria-labelledby="ek-three-areas"] > article:has(> :is(img,figure):first-child + :is(h2,h3,h4) + p + :is(ul,ol) + :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child) {display:grid!important;grid-row:span 5;grid-template-rows:subgrid;row-gap:0;align-items:start;}
    body.wp-singular main#content#content.site-main .page-content section[aria-labelledby="ek-three-areas"] > article:has(> :is(img,figure):first-child + :is(h2,h3,h4) + p + :is(ul,ol) + :is(a.ek-wa-cta,a.ekosphere-contact-form-cta,.ekosphere-cta-pair,.ek-card__cta):last-child) > :last-child {margin-block:0!important;align-self:end;justify-self:center;}
  }
}

/* Keep bullet lists readable in cards at every screen width. */
body.wp-singular main#content#content.site-main .page-content :is(article,.ek-card,.ekds-lp-card,.ekds-lp-tile,.ek-tile) :is(ul,ol,li) {text-align:left!important;}

/* FAQ accordion appearance shared with Estate. */
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) {width:100%;margin-inline:0;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details {box-sizing:border-box;margin:0 0 16px;padding:0;border:1px solid #5a3e2b;border-radius:2px;background:#fff;color:#2a211b;font:400 20px/33px Roboto,system-ui,-apple-system,"Segoe UI",Arial,sans-serif;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details:first-of-type {margin-top:23px;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > summary {display:list-item;list-style-position:inside;margin:0;padding:12px 16px;border:0;background:#f9fafb;color:#2a211b;font:inherit;text-align:start;cursor:pointer;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > summary:focus-visible {outline:2px solid #5a3e2b;outline-offset:-3px;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > :not(summary) {margin:0;padding:0 16px 10px;background:#fff;color:inherit;font:inherit;text-align:start;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > summary + :not(summary) {border-top:1px solid #5a3e2b;padding-top:12px;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > :not(summary):last-child {padding-bottom:14px;}
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details > :is(ul,ol) {padding-inline-start:40px;}

/* Editorial links inherit their text color and emphasize only on interaction. */
body:not(.wp-admin) main#content#content.site-main .page-content a[href]:not(:is(.ek-wa-cta,.ekosphere-contact-form-cta,.ek-btn,.button,.wp-element-button,.wp-block-button__link,.elementor-button,.ekds-lp-button,[role="button"],[class*="cta"],[href^="https://wa.me/"],[href*="whatsapp.com/"],section[aria-labelledby*="hero"] > a)) {color:inherit!important;text-decoration:none!important;border-bottom:0!important;font-weight:400!important;}
body:not(.wp-admin) main#content#content.site-main .page-content a[href]:not(:is(.ek-wa-cta,.ekosphere-contact-form-cta,.ek-btn,.button,.wp-element-button,.wp-block-button__link,.elementor-button,.ekds-lp-button,[role="button"],[class*="cta"],[href^="https://wa.me/"],[href*="whatsapp.com/"],section[aria-labelledby*="hero"] > a)):is(:hover,:focus-visible) {color:inherit!important;text-decoration:none!important;font-weight:700!important;}
body.wp-singular main#content.site-main .page-content > [data-ekosphere-page-hero] {margin-bottom:0;}
body.wp-singular main#content.site-main:has(.page-content .ekosphere-text-hero) > .page-header {display:none;}

/* Open accordions use a visibly deeper tone than closed triggers. */
body.wp-singular main#content#content.site-main .page-content section:is([aria-labelledby*="faq" i],.ek-faq) details[open] > summary {background:#d1d5db!important;color:#2a211b!important;}
body.wp-singular main#content#content.site-main .page-content nav[aria-labelledby="ek-toc-title"] details[open] > summary {background:#291c14!important;color:#fff!important;}

/* Thin borders for images and cards, with a shadow on CTA interaction. */
body.wp-singular main#content#content.site-main .page-content :is(img:not(.ek-wa-icon,[class*="contact-icon"],[src*="/contact-icons/"]),article,.ek-card,.ekds-lp-card,.ekds-lp-tile,.ekds-lp-review-card,.ek-tile,.ek-real-estate-card) {box-sizing:border-box;border:1px solid #d5e2df;}
body:not(.wp-admin) main#content#content.site-main .page-content a[href]:is(.ek-wa-cta,.ekosphere-contact-form-cta,.ek-btn,.button,.wp-element-button,.wp-block-button__link,.elementor-button,.ekds-lp-button,[role="button"],[class*="cta"],.ekosphere-cta-pair > a,section[aria-labelledby*="hero"] > a):is(:hover,:focus-visible),
body .planb-footer a.planb-footer__cta:is(:hover,:focus-visible),body .planb-nav a.planb-nav__link--cta:is(:hover,:focus-visible) {box-shadow:var(--ekosphere-hover-shadow)!important;}
body:not(.wp-admin) main#content#content.site-main .page-content li > a.ek-wa-cta:is(:hover,:focus-visible) {box-shadow:none!important;}

/* Shared heading scale and deliberate spacing at section transitions. */
body.wp-singular main#content#content.site-main .page-content {--ek-title-gap:clamp(1.75rem,3.2vw,2.75rem);--ek-title-after:clamp(1rem,1.8vw,1.5rem);}
body.wp-singular main#content#content.site-main .page-content h1 {font-size:clamp(1.8rem,3.1vw,2.5rem)!important;line-height:1.18!important;}
body.wp-singular main#content#content.site-main .page-content h2 {font-size:clamp(1.55rem,2.65vw,2.125rem)!important;line-height:1.2!important;}
body.wp-singular main#content#content.site-main .page-content h3 {font-size:clamp(1.24rem,1.9vw,1.5rem)!important;line-height:1.25!important;}
body.wp-singular main#content#content.site-main .page-content h4 {font-size:clamp(1.12rem,1.5vw,1.25rem)!important;line-height:1.3!important;}
body.wp-singular main#content#content.site-main .page-content section:has(+ section > :is(h1,h2,h3,h4):first-child) {margin-block-end:0!important;}
body.wp-singular main#content#content.site-main .page-content section:has(+ section > :is(h1,h2,h3,h4):first-child) > :last-child {margin-block-end:0!important;}
body.wp-singular main#content#content.site-main .page-content section + section:has(> :is(h1,h2,h3,h4):first-child) {padding-block-start:var(--ek-title-gap)!important;}
body.wp-singular main#content#content.site-main .page-content section + section > :is(h1,h2,h3,h4):first-child {margin-block:0 var(--ek-title-after)!important;}
body.wp-singular main#content#content.site-main .page-content section > :not(:is(article,h1,h2,h3,h4)):has(+ :is(h2,h3,h4)) {margin-block-end:0!important;}
body.wp-singular main#content#content.site-main .page-content section > :not(:is(h1,h2,h3,h4)) + :is(h2,h3,h4) {margin-block:var(--ek-title-gap) var(--ek-title-after)!important;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-copy h3 {font-size:20px!important;}

/* A consistent label-and-value layout for facts throughout the site. */
body.wp-singular main#content#content.site-main .page-content dl {margin:1.25rem 0 1.75rem;text-align:start;}
body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) {display:grid;grid-template-columns:minmax(10rem,23%) minmax(0,1fr);margin:1.25rem 0 1.75rem;border:1px solid #d5e2df;border-radius:2px;background:#fff;}
body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > :is(dt,dd) {margin:0!important;padding:.72rem 1rem;border:0;border-top:1px solid #d5e2df;text-align:start!important;line-height:1.5;min-width:0;overflow-wrap:anywhere;}
body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > dt {grid-column:1;font-weight:700;background:#f3f7f6;color:#12343a;}
body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > dd {grid-column:2;color:#193037;}
body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > :is(dt:first-of-type,dd:first-of-type) {border-top:0;}
body.wp-singular main#content#content.site-main .page-content dl > div {padding:.75rem 1rem;border-bottom:1px solid #d5e2df;text-align:start;}
body.wp-singular main#content#content.site-main .page-content dl > div > dt {font-weight:700;color:#12343a;}
body.wp-singular main#content#content.site-main .page-content dl > div > dd {margin:0!important;}
@media (max-width:640px) {
  body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) {grid-template-columns:minmax(0,1fr);}
  body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > dt {padding:.65rem .85rem .15rem;background:#f3f7f6;}
  body.wp-singular main#content#content.site-main .page-content dl:has(> dt + dd):not(:has(> div)) > dd {grid-column:1;padding:.1rem .85rem .65rem;border-top:0;background:#f3f7f6;}
}

/* Align content headings with the reading edge. */
body.wp-singular main#content#content.site-main :is(.page-content,.page-header) :is(h1,h2,h3,h4,h5,h6) {text-align:left!important;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-card .ekosphere-profile-copy h3 {text-align:center!important;}

/* Navigation containing topic cards uses the same responsive card structure. */
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) {display:grid!important;grid-template-columns:minmax(0,1fr);gap:clamp(.85rem,2vw,1.5rem);align-items:stretch;padding:0!important;border:0!important;background:transparent!important;}
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) > article {display:flex;flex-direction:column;min-width:0;padding:clamp(1rem,2vw,1.5rem);background:#f6f9f8;border:1px solid #d5e2df;border-radius:2px;box-shadow:var(--ekosphere-surface-shadow)!important;}
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) > article:is(:hover,:focus-within) {box-shadow:var(--ekosphere-hover-shadow)!important;}
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) > article > :is(figure,img) {width:100%;max-width:100%;}
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) > article > figure > img {width:100%;aspect-ratio:16/9;object-fit:cover;}
body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) > article > a:last-child {align-self:flex-start;margin-top:auto;}
@media(min-width:761px){body.wp-singular main#content#content.site-main .page-content nav:has(> article + article) {grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(min-width:1040px){body.wp-singular main#content#content.site-main .page-content nav:has(> article + article):has(> article:nth-child(3)) {grid-template-columns:repeat(3,minmax(0,1fr));}}



/* Balance long page headings on the 70% content measure. */
body.wp-singular main#content#content.site-main :is(.page-content,.page-header) :is(h1,h2,h3,h4,h5,h6):not(:where(article *,.ek-card *,.ekds-lp-card *,.ekds-lp-tile *,.ek-tile *)) {max-inline-size:70%;text-wrap:balance;}
body.wp-singular main#content#content.site-main :is(.page-content,.page-header) :is(h1,h2,h3,h4,h5,h6):has(br) {max-inline-size:100%;}

/* A standalone editorial article with an H2 belongs to the reading flow. */
body.wp-singular main#content#content.site-main .page-content section > article:only-child:has(> h2):not([data-ds-profile],.ek-card,.ekds-lp-card,.ek-real-estate-card) {display:block;border:0!important;padding:0;background:transparent!important;box-shadow:none!important;}
body.wp-singular main#content#content.site-main .page-content section > article:only-child:has(> h2):not([data-ds-profile],.ek-card,.ekds-lp-card,.ek-real-estate-card) > .ekosphere-card-image {display:none!important;}

/* Aligned markers for suitability and use-case lists. */
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list {list-style:none!important;padding-inline-start:0!important;margin-inline-start:0!important;}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list > li {position:relative;list-style:none!important;margin-inline-start:0!important;padding-inline-start:1.65em!important;text-align:start!important;}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list > li::marker {content:"";}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list > li::before {content:var(--ek-list-icon);color:var(--ek-list-color);position:absolute;inset-inline-start:0;inset-block-start:0;display:grid;place-items:center;width:1.2em;height:1lh;font-weight:800;font-family:system-ui,sans-serif;}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list.ekosphere-semantic-list--yes {--ek-list-icon:"✓";--ek-list-color:#157547;}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list.ekosphere-semantic-list--no {--ek-list-icon:"×";--ek-list-color:#b72535;}
body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list.ekosphere-semantic-list--use {--ek-list-icon:"→";--ek-list-color:#00817f;}

body.wp-singular main#content#content.site-main .page-content ul.ekosphere-semantic-list.ekosphere-semantic-list--use > li::before {content:"";background:var(--ek-list-color);-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 12h17m-6-6 6 6-6 6'/%3E%3C/svg%3E") center / 1.08em 1.08em no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 12h17m-6-6 6 6-6 6'/%3E%3C/svg%3E") center / 1.08em 1.08em no-repeat;}

/* Put DS profile names in the lower-left corner of the portrait. */
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-photo {position:relative;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-photo > .ekosphere-profile-caption {position:absolute;inset:auto 1px 1px;padding:.62rem clamp(.8rem,2vw,1.25rem);margin:0;background:linear-gradient(90deg,rgba(12,24,26,.84) 0%,rgba(12,24,26,.78) 34%,rgba(12,24,26,.38) 58%,rgba(12,24,26,0) 88%);color:#fff;text-align:left;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-photo > .ekosphere-profile-caption h3 {font-size:18px!important;font-style:normal!important;line-height:1.25!important;margin:0!important;color:#fff!important;text-align:left!important;}

/* Center standalone actions and their grouped layouts. */
body:not(.wp-admin) main#content#content.site-main .page-content .ekosphere-cta-pair {margin-inline:auto!important;justify-self:center!important;}
body:not(.wp-admin) main#content#content.site-main .page-content :is(.ek-card__cta,.ekds-lp-primary-cta) {justify-content:center;text-align:center;}
body:not(.wp-admin) main#content#content.site-main .page-content a[href]:is(.ek-wa-cta,.ekosphere-contact-form-cta,.ek-btn,.button,.wp-element-button,.wp-block-button__link,.elementor-button,.ekds-lp-button,[role="button"],[class*="cta"]):not(:where(li > a,.ekosphere-cta-pair > a)) {display:flex!important;width:fit-content!important;margin-inline:auto!important;justify-self:center!important;justify-content:center!important;text-align:center;}

/* Profile grids share the full page-content edges. */
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid {width:100%;max-width:none;margin-inline:0;}

/* Align profile descriptions across each desktop row. */
body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-copy > p:not(.ekosphere-profile-role) {text-align:start!important;hyphens:auto;}
@supports (grid-template-rows:subgrid) {
  @media (min-width:761px) {
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid > .ekosphere-profile-card {display:grid;grid-row:span 3;grid-template-rows:subgrid;row-gap:0;}
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-photo {grid-row:1;}
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-copy {display:grid;grid-row:2 / span 2;grid-template-rows:subgrid;row-gap:0;align-items:start;}
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-role {grid-row:1;}
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-copy > p:not(.ekosphere-profile-role) {grid-row:2;}
    body.wp-singular main#content#content.site-main .page-content .ekosphere-profile-grid .ekosphere-profile-card:not(:has(.ekosphere-profile-photo)) .ekosphere-profile-copy {display:block;grid-row:1 / -1;}
  }
}

/* Compact review cards and Google Maps rating breakdown. */
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card {padding:clamp(.85rem,1.6vw,1.25rem)!important;background:#fff;border-color:#dee7e5;box-shadow:none!important;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card:is(:hover,:focus-within) {box-shadow:0 2px 8px #122e3916!important;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card h3 {font-size:18px!important;line-height:1.3!important;margin:0 0 .55rem!important;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card :is(p,summary) {font-size:15px;line-height:1.45;margin:0 0 .5rem;text-align:left;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-review-maps h3 a {display:inline-flex;gap:.5rem;align-items:center;font-weight:700!important;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-review-maps h3 a::before {display:none!important;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-maps {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  align-items: center;
  gap: clamp(1rem, 3vw, 2rem);
  padding: clamp(1.25rem, 3vw, 2rem) !important;
}
body.wp-singular main#content#content.site-main .page-content .ekosphere-review-maps-identity {
  min-width: 0;
  text-align: center;
}
body.wp-singular main#content#content.site-main .page-content .ekosphere-review-maps-identity > .ekosphere-review-maps-brand {
  display: grid;
  place-items: center;
  margin: 0;
}
body.wp-singular main#content#content.site-main .page-content .ekosphere-review-maps-brand > .ekosphere-maps-brand-icon {
  display: block;
  width: clamp(72px, 60%, 124px);
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
  border: 0 !important;
  box-shadow: none !important;
}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-maps > .ekosphere-review-summary {
  margin-top: 0;
}
body.wp-singular main#content#content.site-main .page-content section[aria-labelledby="ek-bewertungsstand"] > .ekosphere-review-maps + article {
  grid-column: 1 / -1;
  width: min(100%, 578px);
  justify-self: center;
}
@media (max-width: 640px) {
  body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-maps {
    grid-template-columns: minmax(0, 1fr);
  }
}
.ekosphere-review-summary {display:grid;grid-template-columns:minmax(0,1fr) auto;gap:clamp(.7rem,2.2vw,1.4rem);align-items:center;margin-top:.85rem;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-rating-bars {list-style:none;margin:0!important;padding:0!important;}
body.wp-singular main#content#content.site-main .page-content .ekosphere-rating-bars > li {display:grid;grid-template-columns:1em minmax(0,1fr);align-items:center;gap:.45rem;margin:0!important;padding:0!important;font-size:13px;line-height:1.5;color:#4b5563;}
.ekosphere-rating-bar {display:block;height:6px;background:#eceff1;border-radius:10px;overflow:hidden;}
.ekosphere-rating-bar > span {display:block;height:100%;border-radius:inherit;background:#fbbc04;}
.ekosphere-rating-score {display:grid;justify-items:center;gap:.18rem;font-size:14px;white-space:nowrap;}
.ekosphere-rating-score strong {font-size:1.65rem;line-height:1.1;}
.ekosphere-rating-score small {font-size:.78rem;}
.ekosphere-maps-stars {display:inline-block;width:70px;height:14px;background:repeat-x left center / 14px 14px url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAABiElEQVR4Ae1WJVA+cRBdXNPf3YVExp1eaEgf3Im4RQrukEi43s2XcIdGx92dZRfn+NzQN/POVt7PdufgBfJw2GWewQRjYLfD+uehYI7MPdHqtzFml8BiZxTN48HQIKFeIl6wBwwJFOEziZzcEDxBGXwBQ+FAtAhnoZs8ECzCDLmcolSQ9lEAQwAFeE0Ch0SU8IiW9Y3mo+80d6XRJikiLV0lC8gj25TFko+zvOUaJqKBOCKvvrzIMGsAMc7pDfKArfCWhBv0KNaO7fARVOGoyyyEnLd0ENqlfY1CBBNQF/sdlg5a7atoPrkvWDqCNqAltqKR1qgrxr4cA7rgSDArU1eQfEtBF6AMzCnRogZLusQxurQyfyJqSD/QFnRaCxQknWLKs3EMaANMAVNKMHPnYHRZVNOy2WMP2NB7nhzROawDM216q6ck0QYdiiA5hyqAbKuS0vAATSEZ/YCy/xe2sc8N/zzQFFRTtRR4QszFIbAAFWAf9uUYiq3SpiSsd2XwQ5u/Oo6FZ4tT4mLYm81lTkgAAAAASUVORK5CYII=);clip-path:inset(0 calc((5 - var(--ek-stars,5)) * 20%) 0 0);}

/* Review bylines, accessible native accordions and a gold hover state. */
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card :is(p.ekosphere-review-byline) {display:flex;align-items:center;gap:.55rem;margin:0 0 .75rem;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card .ekosphere-review-byline .ekosphere-maps-stars {flex:0 0 70px;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card {transition:background-color .18s ease,box-shadow .18s ease;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card:is(:hover,:focus-within,:has(details[open])) {background:rgba(251,188,4,.20)!important;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details {border:1px solid #e1e7e5;border-radius:2px;overflow:hidden;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details > summary {display:flex;align-items:center;gap:.55rem;list-style:none;margin:0;padding:.55rem .65rem;background:#f5f7f6;font-size:14px!important;font-weight:400!important;cursor:pointer;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details > summary::-webkit-details-marker {display:none;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details[open] > summary {background:#dce4e1;}
body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details > :not(summary) {margin:0;padding:.65rem;border-top:1px solid #e1e7e5;background:#fff;}

body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details > summary:hover {font-weight:700!important;}

body.wp-singular main#content#content.site-main .page-content article.ekosphere-review-card details :is(p,blockquote) {text-align:start!important;}

/* Standard crop for editorial hero and content-card images. */
body.wp-singular main#content#content.site-main .page-content > figure[data-ekosphere-page-hero] > img,
body.wp-singular main#content#content.site-main .page-content > figure[data-ekosphere-page-hero] > picture > img {display:block;width:100%;height:auto;aspect-ratio:16/9!important;object-fit:cover;object-position:center;}
body.wp-singular main#content#content.site-main .page-content article:not(.ekosphere-profile-card,.ekosphere-review-card) > :is(img:first-child,.ekosphere-card-image),
body.wp-singular main#content#content.site-main .page-content article:not(.ekosphere-profile-card,.ekosphere-review-card) > figure:first-child img {display:block;width:100%;height:auto;aspect-ratio:16/9!important;object-fit:cover;object-position:center;}

/* Give all rows in a pure editorial card group the same height at each breakpoint. */
body.wp-singular main#content#content.site-main .page-content :is(nav,section,.ek-grid,.ekds-lp-card-grid):has(> article + article):not(:has(> :not(article))):not(.ekosphere-profile-grid) {grid-auto-rows:1fr;align-items:stretch;}

/* A consistent logo mark over editorial hero images. */
body.wp-singular main#content#content.site-main .page-content > figure[data-ekosphere-page-hero] {position:relative;isolation:isolate;}
body.wp-singular main#content#content.site-main .page-content > figure[data-ekosphere-page-hero]::after {content:"";position:absolute;z-index:1;inset-block-start:clamp(12px,2.1vw,24px);inset-inline-start:clamp(12px,2.1vw,24px);width:clamp(50px,5.8vw,86px);aspect-ratio:1;background:url("https://ekosphere.me/wp-content/uploads/2026/03/stylized-globe-design-in-blue-for-ekosphere-me-ulcinj-advice-on-emigration-company-formation-re.webp") center/contain no-repeat;filter:drop-shadow(0 1px 3px rgb(255 255 255 / 38%));pointer-events:none;}

/* Hide the parent-theme title when the article already has its own heading. */
body.wp-singular main#content.site-main:has(> .page-content > [data-ekosphere-page-hero]):has(> .page-content h1) > .page-header {display:none!important;}

/* Editorial category labels must not precede the title below the contents. */
body.wp-singular main#content .page-content header[aria-labelledby] > p:not([itemprop]):has(+ h1) { display: none !important; }

/* Shared accordion appearance for the Relaunch content. */
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) { box-sizing:border-box; width:100%; margin:0 0 12px!important; padding:0!important; border:1px solid #d5e2df!important; border-radius:2px; background:#fff; overflow:hidden; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > summary { display:list-item!important; list-style:revert!important; list-style-position:inside!important; margin:0!important; padding:11px 15px!important; border:0!important; background:#f4f7f6!important; color:#173135!important; font-weight:400!important; cursor:pointer; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > summary:is(:hover,:focus-visible) { font-weight:700!important; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc)[open] > summary { background:#c9d7d3!important; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > :not(summary) { margin:0!important; padding:10px 15px!important; border:0!important; background:#fff!important; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > :is(ul, ol) { padding-inline-start: 2.5rem !important; }
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > summary::before,
body.wp-singular main#content .page-content details[name="ekosphere-content-accordion"]:not(#ek-toc) > summary::after { content:none!important; display:none!important; }
body.wp-singular main#content .page-content details:has(> .eko-review-meta) > summary,
body.wp-singular main#content .page-content .ekosphere-review-card details > summary { font-size:14px!important; }
body.wp-singular main#content .page-content details:has(> .eko-review-meta) > p,
body.wp-singular main#content .page-content .ekosphere-review-card details > p { text-align:start!important; }
.eko-review-stars { color:#a46500; margin-inline-end:.45em; white-space:nowrap; }

/* Use one space of horizontal separation between button icons and labels. */
:root { --ek-button-icon-gap: .25em; }
html[lang] body:not(.wp-admin) :is(main#content#content, #ekosphere-contact-popup, header.planb-header, footer.planb-footer) :is(
    .ekosphere-cta-pair > :is(a,button), .ekosphere-contact-form-cta, .ek-wa-cta, .ekosphere-wa-number,
    .eko-office-reviews__action, .ek-btn, a.button, .wp-element-button, .wp-block-button__link,
    .elementor-button, .ekds-lp-button, .ek-journey-action, .ek-real-estate-card__cta,
    .ep-button, .ep-source, .ekosphere-review-maps h3 a, .planb-footer__cta, .planb-nav__link--cta,
    .eko-contact-form button[type="submit"], #eko-contact-form button[type="submit"]
),
.elementor-button .elementor-button-content-wrapper {
    column-gap: var(--ek-button-icon-gap) !important;
}
html[lang] body:not(.wp-admin) :is(main#content#content, #ekosphere-contact-popup, header.planb-header, footer.planb-footer) :is(
    .ekosphere-cta-pair > :is(a,button), .ekosphere-contact-form-cta, .ek-wa-cta, .ekosphere-wa-number,
    .eko-office-reviews__action, .ek-btn, a.button, .wp-element-button, .wp-block-button__link,
    .elementor-button, .ekds-lp-button, .ek-journey-action, .ek-real-estate-card__cta,
    .ep-button, .ep-source, .ekosphere-review-maps h3 a, .planb-footer__cta, .planb-nav__link--cta,
    .eko-contact-form button[type="submit"], #eko-contact-form button[type="submit"]
) > :is(.ekosphere-form-icon,.eko-contact-email-icon,.ek-wa-icon,.ek-outbound-icon,.ep-action-icon,.ep-source-icon,img[alt=""],svg[aria-hidden="true"],[data-icon]),
.elementor-button .elementor-button-icon,
html[lang] body:not(.wp-admin) :is(#eko-contact-form,.eko-contact-form) button[type="submit"]:not(.eko-has-mail-icon)::before {
    margin-inline: 0 !important;
}

/* Contact form layout shared by both languages. */
#eko-contact-form { display:grid; gap:12px; width:100%; margin:0; }
#eko-contact-form h3 { margin:0 0 4px!important; }
#eko-contact-form label { display:grid; gap:4px; font-weight:600; }
#eko-contact-form :is(input:not([type="hidden"]),textarea) { box-sizing:border-box; width:100%; padding:9px 11px; background:#fff; border:1px solid #9eb8b3; border-radius:2px; color:#193037; font:inherit; font-weight:400; }
#eko-contact-form textarea { resize:vertical; }
#eko-contact-form :is(input,textarea,button):focus-visible { outline:2px solid #195b56; outline-offset:2px; }
#eko-contact-form .eko-contact-privacy { margin:0; font-size:.88em; }
#eko-contact-form button { justify-self:center; padding:12px 20px; border:1px solid #195b56; border-radius:2px; background:#195b56!important; color:white!important; font-weight:700; }
#eko-contact-form button:hover { box-shadow:0 5px 12px #17313533!important; }

/* Envelope replaces any generic link marker on email actions. */
html body:not(.wp-admin) :is(main#content#content,footer) a[href^="mailto:" i]:not(.eko-has-mail-icon,.eko-office-reviews__mail,#eko20-request-email)::before,
html body:not(.wp-admin) #eko-contact-form button[type="submit"]:not(.eko-has-mail-icon)::before {
    content:"✉"!important; display:inline-block!important; width:auto!important; height:auto!important;
    margin:0 .45em 0 0!important; padding:0!important; background:none!important;
    -webkit-mask:none!important; mask:none!important; color:inherit; font:inherit; line-height:1;
}

/* Side-by-side suitability lists, stacked on narrow screens. */
.ekosphere-suitability-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; margin-block:24px; }
.ekosphere-suitability-card { min-width:0; padding:clamp(16px,2.25vw,28px); background:#f4f8f7; border:1px solid #d5e2df; border-radius:2px; box-shadow:var(--ekosphere-surface-shadow); }
.ekosphere-suitability-card:hover { box-shadow:var(--ekosphere-hover-shadow); }
body.wp-singular main#content#content.site-main .page-content .ekosphere-suitability-card > :is(h2,h3,h4,h5,h6) { max-inline-size:none; margin:0 0 14px!important; }
body.wp-singular main#content#content.site-main .page-content .ekosphere-suitability-card > ul { margin-block:0!important; text-align:start!important; }
@media(max-width:760px) { .ekosphere-suitability-grid { grid-template-columns:minmax(0,1fr); gap:14px; } }

/* Match the spacing of CTA rows and adjacent cards throughout the site. */
body:not(.wp-admin) main#content#content .ekosphere-suitability-grid:has(+ :is(.ekosphere-cta-pair,.wp-block-buttons)) {
  margin-block-end: 0;
}
body:not(.wp-admin) main#content#content .page-content .wp-block-buttons {
  gap: 24px;
  margin-block-start: 36px;
}
@media (max-width: 760px) {
  body:not(.wp-admin) main#content#content .page-content .wp-block-buttons {
    gap: 14px;
    margin-block-start: 24px;
  }
}

@media (min-width: 1040px) {
  body.wp-singular main#content#content.site-main .page-content nav[aria-labelledby="ek-aufenthaltswissen-ueberblick"]:has(> article + article):has(> article:nth-child(3)) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}


/* Footer company teaser and social links. */
footer.planb-footer .planb-footer__brand .planb-footer__teaser {
    margin: .65rem 0 .85rem;
    font-size: .92rem;
    line-height: 1.55;
    text-align: start;
    hyphens: auto;
}
footer.planb-footer .planb-footer__brand .planb-footer__cta-wrap {
    display: flex !important;
    justify-content: center !important;
    width: 100%;
}
footer.planb-footer .planb-footer__socials .planb-footer__link {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
}
footer.planb-footer .planb-footer__social-icon {
    display: block;
    width: 19px;
    height: 19px;
    flex: none;
    object-fit: contain;
}

footer.planb-footer .planb-footer__socials a.planb-footer__link.ek-wa-cta {
    display: inline-flex !important;
    justify-content: flex-start;
    gap: .5rem;
    color: inherit !important;
    -webkit-text-fill-color: currentColor !important;
    background: transparent !important;
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    min-height: 0 !important;
    box-shadow: none !important;
    text-decoration: none !important;
}
footer.planb-footer .planb-footer__socials .ek-wa-icon {
    display: block;
    width: 19px !important;
    height: 19px !important;
    margin: 0 !important;
    flex: none;
    object-fit: contain;
}


/* WhatsApp CTA in the standalone property detail template. */
html body.ekex-real-estate-detail main#ekex-real-estate-detail-content a.ek-real-estate-detail__contact--whatsapp {
    background: #137344 !important;
    border-color: #0f6139 !important;
    color: #fff !important;
}
html body.ekex-real-estate-detail main#ekex-real-estate-detail-content a.ek-real-estate-detail__contact--whatsapp:hover {
    background: #0b5732 !important;
    border-color: #0b5732 !important;
}

/* The accordion already defines the content width for additional offers. */
main#content #ek-liegenschaften-angebote-block > .ek-real-estates__more > [data-ekex-more-offers] {
    width: 100% !important;
    max-width: none !important;
}


@layer ekosphere-typography {
  /* Justified prose with language-aware text wrapping. Lists and accordions use start alignment. */
  body:not(.wp-admin) :is(main#content#content.site-main .page-content, main .entry-content, footer.planb-footer)
    :is(p, blockquote, figcaption, li, dd):not(:where(nav *, pre *, code *, [role="menu"] *, .wp-block-buttons *, .ekosphere-cta-pair *)) {
    word-spacing: normal;
    word-break: normal;
    overflow-wrap: anywhere;
    -webkit-hyphens: auto;
    hyphens: auto;
    hyphenate-limit-chars: 6 2 2;
    text-wrap: pretty;
  }

  body:not(.wp-admin) :is(main#content#content.site-main .page-content, main .entry-content, footer.planb-footer)
    :is(p, blockquote, figcaption, .ek-note, .ekex-decision-note, .eko-legal-disclaimer):not(:where(ul *, ol *, details *, nav *, pre *, code *, [role="menu"] *, .wp-block-buttons *, .ekosphere-cta-pair *, .has-text-align-center, .has-text-align-right, .has-text-align-end)) {
    text-align: justify !important;
    text-align-last: start !important;
    text-justify: inter-word !important;
    letter-spacing: normal !important;
    text-wrap: wrap !important;
  }

  body:not(.wp-admin) :is(main#content#content.site-main .page-content, main .entry-content, footer.planb-footer)
    :is(ul, ol, details):not(:where(nav *, [role="menu"] *)),
  body:not(.wp-admin) :is(main#content#content.site-main .page-content, main .entry-content, footer.planb-footer)
    :is(ul, ol, details):not(:where(nav *, [role="menu"] *)) :is(li, p, blockquote, figcaption, summary, .ek-note, .ekex-decision-note, .eko-legal-disclaimer) {
    text-align: start !important;
    text-align-last: start !important;
  }
}

/* Match the quick-menu branding in the site-owned dialogs. */
:is(#ek-glossary-title, #ekosphere-link-preview-title, #ek-price-preview-title,
    #ekosphere-contact-popup-title, #ekosphere-contact-confirmation-title, #eko-contact-privacy-title) {
    display: flex;
    align-items: center;
    gap: 10px;
    min-inline-size: 0;
}

:is(#ek-glossary-title, #ekosphere-link-preview-title, #ek-price-preview-title,
    #ekosphere-contact-popup-title, #ekosphere-contact-confirmation-title, #eko-contact-privacy-title)::before {
    content: "";
    flex: 0 0 36px;
    block-size: 36px;
    background: url("/wp-content/plugins/ekosphere-DS/assets/ekosphere-ds-globe.webp") center / contain no-repeat;
}

#ek-glossary-dialog .ek-glossary-actions button {
    background-color: #00647b;
    border-color: #00647b;
    border-radius: 6px;
    color: #fff;
    cursor: pointer;
}

#ek-glossary-dialog .ek-glossary-actions button:is(:hover, :focus) {
    background-color: #004b5d;
    border-color: #004b5d;
    color: #fff;
}

#ek-glossary-dialog .ek-glossary-actions button:focus-visible {
    outline: 2px solid #00647b;
    outline-offset: 3px;
}

/* Keep one full text line between content media and the copy below it. */
@layer ekosphere-image-spacing {
  body:not(.wp-admin) :is(main, .entry-content) :is(
    img:not(:where(.avatar, .emoji, .wp-smiley, [class*="-icon"], [src*="/contact-icons/"])),
    picture:has(> img),
    figure:has(img):not(:has(> figcaption:not(:where(.ekosphere-profile-caption, [class*="overlay"])))),
    :is(div.wp-block-image, div.wp-caption):has(img):not(:has(.wp-caption-text, figcaption)),
    :is(a, p):has(> :is(img, picture):only-child):not(:has(img[class*="-icon"], img[src*="/contact-icons/"]))
  ):has(+ :is(h1, h2, h3, h4, h5, h6, p, ul, ol, dl, blockquote, details, .ekosphere-profile-copy)),
  body:not(.wp-admin) :is(main, .entry-content) p > img:not(:where(.avatar, .emoji, .wp-smiley, [class*="-icon"], [src*="/contact-icons/"])):has(+ br) {
    margin-block-end: 2rem !important;
    margin-block-end: max(2rem, 1lh) !important;
  }

  body:not(.wp-admin) :is(main, .entry-content) :is(figure, .wp-caption):has(img)
    > :is(figcaption, .wp-caption-text):not(:where(.ekosphere-profile-caption, [class*="overlay"])) {
    margin-block-start: 2rem !important;
    margin-block-start: max(2rem, 1lh) !important;
  }

  body:not(.wp-admin) :is(main, .entry-content) .ek-real-estate-card:has(> .ek-real-estate-card__media img) > .ek-real-estate-card__body {
    padding-block-start: 2rem !important;
    padding-block-start: max(2rem, 1lh) !important;
  }

  body:not(.wp-admin) :is(main, .entry-content) :is(a, picture):has(> img:only-child):has(+ :is(h1, h2, h3, h4, h5, h6, p, ul, ol, dl, blockquote, details)) {
    display: block;
  }
}
