/* Desktop hero: a full-width portrait that fades out beneath the text. */
.hero {
  position: relative;
  isolation: isolate;
  min-height: 720px;
  overflow: hidden;
  background: #f8f5ef;
}

.hero .hero-grid {
  display: block;
}

.hero .hero-grid > :first-child {
  position: relative;
  z-index: 2;
  width: min(630px, 53vw);
  padding: 34px 0 74px;
}

.hero .hero-photo--wide {
  position: absolute;
  z-index: 0;
  inset: 0;
  width: 100%;
  max-width: none;
  overflow: hidden;
}

.hero .hero-photo--wide img {
  width: 100%;
  max-width: none;
  height: 100%;
  border-radius: 0;
  box-shadow: none;
  object-fit: cover;
  object-position: center 28%;
  transform: none;
}

.hero .hero-photo--wide::after {
  position: absolute;
  z-index: 1;
  inset: 0;
  content: "";
  pointer-events: none;
  background: linear-gradient(
    90deg,
    #f8f5ef 0%,
    #f8f5ef 31%,
    rgba(248, 245, 239, .98) 39%,
    rgba(248, 245, 239, .76) 45%,
    rgba(248, 245, 239, .28) 51%,
    rgba(248, 245, 239, 0) 56%
  );
}

.hero .hero-photo--wide .hero-card {
  display: none;
  z-index: 2;
  right: clamp(22px, 4vw, 74px);
  bottom: 38px;
  left: auto;
  width: min(330px, 28vw);
}

.trust-strip {
  position: relative;
  z-index: 3;
}

@media (max-width: 980px) {
  .hero {
    min-height: 0;
    padding: 52px 0 0;
  }

  .hero .hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero .hero-grid > :first-child {
    width: auto;
    padding: 0;
  }

  .hero .hero-photo--wide {
    position: relative;
    inset: auto;
    width: 100%;
    overflow: visible;
  }

  .hero .hero-photo--wide img {
    width: 100%;
    height: 600px;
    border-radius: 8px;
    box-shadow: var(--shadow);
    transform: none;
  }

  .hero .hero-photo--wide::after {
    background: linear-gradient(180deg, rgba(248, 245, 239, 0) 58%, rgba(248, 245, 239, .45) 100%);
  }

  .hero .hero-photo--wide .hero-card {
    display: block;
    right: auto;
    bottom: auto;
    left: 18px;
    width: min(340px, 78%);
  }
}

@media (max-width: 640px) {
  .hero {
    padding-top: 42px;
  }

  .hero .hero-photo--wide img {
    height: 430px;
  }

  .hero .hero-photo--wide .hero-card {
    position: relative;
    left: auto;
    width: auto;
    margin: -48px 14px 0;
  }
}

/* The expert block uses a second, wide seated portrait with the text on the right. */
#about.section {
  position: relative;
  overflow: hidden;
  padding: 0;
  background: #f8f5ef;
}

#about .expert {
  position: relative;
  display: block;
  min-height: 850px;
  padding: 92px 0;
}

#about .expert-photo--scene {
  position: absolute;
  z-index: 0;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  margin: 0;
  overflow: hidden;
  transform: translateX(-50%);
}

#about .expert-photo--scene img {
  width: 100%;
  max-width: none;
  height: 100%;
  border-radius: 0;
  box-shadow: none;
  object-fit: cover;
  object-position: center;
}

#about .expert-photo--scene::after {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(248, 245, 239, 0) 0%,
    rgba(248, 245, 239, .12) 31%,
    rgba(248, 245, 239, .56) 48%,
    rgba(248, 245, 239, .91) 62%,
    #f8f5ef 74%
  );
}

#about .expert > :not(.expert-photo) {
  position: relative;
  z-index: 1;
  width: min(630px, 53vw);
  margin-left: auto;
}

#about .proof-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 12px;
}

#about .proof {
  padding-inline: 20px;
}

#about .proof:nth-child(2) b,
#about .proof:nth-child(3) b {
  display: block;
  text-align: center;
}

#about .proof,
#about .principle {
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(8px);
}

@media (max-width: 980px) {
  #about .proof-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #about .proof:nth-child(3) {
    grid-column: 1 / -1;
  }

  #about.section {
    padding: 64px 0;
  }

  #about .expert {
    display: grid;
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 0;
  }

  #about .expert-photo--scene {
    position: relative;
    top: auto;
    bottom: auto;
    left: auto;
    width: 100%;
    height: auto;
    transform: none;
  }

  #about .expert-photo--scene img {
    height: 540px;
    border-radius: 6px;
    box-shadow: var(--shadow);
  }

  #about .expert-photo--scene::after {
    background: linear-gradient(180deg, rgba(248, 245, 239, 0) 58%, rgba(248, 245, 239, .42) 100%);
  }

  #about .expert > :not(.expert-photo) {
    width: auto;
    margin-left: 0;
  }
}

@media (max-width: 640px) {
  #about .proof-grid {
    grid-template-columns: 1fr;
  }

  #about .proof:nth-child(3) {
    grid-column: auto;
  }

  #about .expert-photo--scene img {
    height: 430px;
  }
}

/* Dedicated wide image treatment for detail landing heroes */
.landing-hero {
  position: relative;
  isolation: isolate;
  min-height: 720px;
  overflow: hidden;
  padding: 0;
  background: #f8f5ef;
}

.landing-hero .hero-grid { display: block; }

.landing-hero .hero-grid > :first-child {
  position: relative;
  z-index: 2;
  width: min(630px, 53vw);
  padding: 76px 0 74px;
}

.landing-hero .hero-photo--wide {
  position: absolute;
  z-index: 0;
  inset: 0;
  width: 100%;
  max-width: none;
  overflow: hidden;
}

.landing-hero .hero-photo--wide img {
  width: 100%;
  max-width: none;
  height: 100%;
  border-radius: 0;
  box-shadow: none;
  object-fit: cover;
  object-position: center;
}

.landing-hero .hero-photo--wide::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    #f8f5ef 0%,
    #f8f5ef 31%,
    rgba(248, 245, 239, .98) 39%,
    rgba(248, 245, 239, .76) 45%,
    rgba(248, 245, 239, .28) 51%,
    rgba(248, 245, 239, 0) 56%
  );
}

.landing-hero .hero-card { display: none; }

@media (max-width: 980px) {
  .landing-hero {
    min-height: 0;
    padding: 52px 0 0;
  }

  .landing-hero .hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .landing-hero .hero-grid > :first-child {
    width: auto;
    padding: 0;
  }

  .landing-hero .hero-photo--wide {
    position: relative;
    inset: auto;
    width: 100%;
    overflow: hidden;
  }

  .landing-hero .hero-photo--wide img {
    width: 100%;
    height: auto;
    min-height: 420px;
    object-position: center;
  }

  .landing-hero .hero-photo--wide::after {
    background: linear-gradient(180deg, rgba(248,245,239,0) 58%, #f8f5ef 100%);
  }
}
/* Keep the main-page portrait at the same natural scale as detail pages */
.hero .hero-photo--wide {
  inset: 0 0 auto;
  height: 920px;
}

.hero .trust-strip {
  margin-top: 42px;
}

@media (max-width: 980px) {
  .hero .hero-photo--wide {
    height: auto;
  }

  .hero .trust-strip {
    margin-top: 0;
  }
}
/* Preserve headroom in detail hero portraits */
.landing-hero--headroom .hero-photo--wide img {
  object-position: center top;
}
/* Continue the lower edge behind the trust strip without a step */
@media (min-width: 981px) {
  .hero .hero-photo--wide {
    height: 1220px;
  }

  .hero .hero-photo--wide img {
    height: 920px;
  }

  .hero .hero-photo--wide::before {
    content: "";
    position: absolute;
    z-index: 0;
    top: 920px;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(
      90deg,
      #f8f5ef 0%,
      #f8f5ef 46%,
      #0d1c2b 64%,
      #0d1c2b 100%
    );
  }
}

/* Keep the value and its explanation readable as one phrase. */
.metric-band .metric {
  display: flex;
  align-items: baseline;
  gap: .35em;
}

/* FAQ stays at the same readable scale as the site copy. */
.faq-q {
  font-size: 18px;
  line-height: 1.45;
}

.faq-a {
  font-size: 17px;
  line-height: 1.55;
}
/* Use one continuous foundation behind the main trust strip */
@media (min-width: 981px) {
  .hero .hero-photo--wide {
    height: 920px;
  }

  .hero .hero-photo--wide::before {
    content: none;
  }

  .hero::after {
    content: "";
    position: absolute;
    z-index: 1;
    right: 0;
    bottom: 0;
    left: 0;
    height: 240px;
    background: #0d1c2b;
  }
}
/* Move selected seated portraits away from their text columns */
#about.about--shifted-photo .expert-photo--scene img {
  width: 108%;
  transform: translateX(-6%);
}

@media (max-width: 980px) {
  #about.about--shifted-photo .expert-photo--scene img {
    width: 100%;
    transform: none;
  }
}

/* Wide screens: show the full photographs instead of enlarging and cropping them. */
@media (min-width: 981px) {
  .hero .hero-photo--wide {
    inset: 0;
    height: 100%;
    background: #f8f5ef;
  }

  .hero .hero-photo--wide img,
  .landing-hero .hero-photo--wide img {
    object-fit: contain;
    object-position: right top;
  }

  #about .expert {
    display: block;
    min-height: 900px;
    padding: 56px 0 80px;
  }

  #about .expert-photo--scene {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 100vw;
    height: auto;
    margin: 0;
    transform: translateX(-50%);
    border-radius: 0;
    overflow: hidden;
    background: #f8f5ef;
  }

  #about .expert-photo--scene img,
  #about.about--shifted-photo .expert-photo--scene img {
    position: absolute;
    left: calc(50% - 900px);
    top: 0;
    width: 1600px;
    max-width: none;
    height: 900px;
    margin: 0;
    object-fit: cover;
    object-position: left top;
    transform: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 90px, #000 810px, transparent 1120px), linear-gradient(to bottom, #000 0%, #000 78%, transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to right, transparent 0, #000 90px, #000 810px, transparent 1120px), linear-gradient(to bottom, #000 0%, #000 78%, transparent 100%);
    mask-composite: intersect;
    mask-repeat: no-repeat;
  }

  #about .expert-photo--scene::after {
    content: none;
  }

  #about .expert > :not(.expert-photo) {
    width: min(590px, 50%);
    margin-left: auto;
    min-width: 0;
  }
}

/* Keep detail-page portraits anchored to the centered text container. */
@media (min-width: 981px) {
  .landing-hero .hero-photo--wide img {
    position: absolute;
    top: 0;
    left: calc(50% - 780px);
    width: 1600px;
    max-width: none;
    height: auto;
    object-fit: contain;
    object-position: left top;
    -webkit-mask-image: linear-gradient(to right, transparent 26%, rgba(0,0,0,.04) 34%, rgba(0,0,0,.18) 41%, rgba(0,0,0,.45) 48%, rgba(0,0,0,.76) 54%, #000 60%, #000 94%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 26%, rgba(0,0,0,.04) 34%, rgba(0,0,0,.18) 41%, rgba(0,0,0,.45) 48%, rgba(0,0,0,.76) 54%, #000 60%, #000 94%, transparent 100%);
  }
  .landing-hero .hero-photo--wide img[src$="hero-bankrotstvo.png"] {
    left: calc(50% - 820px);
    width: 1800px;
  }
  .landing-hero .hero-photo--wide::after {
    content: none;
  }
}

/* Keep responsive <picture> wrappers aligned with the existing portrait layout. */
.hero-photo picture,
.expert-photo picture {
  display: block;
  width: 100%;
  height: 100%;
}
