/* =========================================================
   Omgeving — Stap 2D / Fix 176
   Pagina-eigen layout en responsive gedrag.
   Sitebrede componenten (container, page-hero, info-card,
   inline-links, typografie-basis) blijven in style.css.
   ========================================================= */

/* Intro en verhaalblokken */

/* Sitebreed intro-ritme: Omgeving gebruikt de ruime informatievariant. */
body.environment-page .page-hero{
  padding-top:var(--tb-flow-hero-top);
  padding-bottom:var(--tb-flow-hero-bottom);
}
body.environment-page .page-hero + section.content{
  padding-top:var(--tb-flow-first-top);
}

.environment-intro{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:38px;
  align-items:center;
}
.environment-intro-card{
  overflow:hidden;
  border:1px solid rgba(22,56,69,.12);
  border-radius:18px;
  background:#fff;
  box-shadow:0 12px 34px rgba(22,56,69,.08);
  margin-bottom:0;
}
.environment-intro-card > div{padding:34px 36px}
.environment-intro-card > img{
  display:block;
  width:100%;
  height:100%;
  min-height:360px;
  object-fit:cover;
  border-radius:0;
}

.story-grid{
  display:grid;
  gap:var(--tb-space-xl);
}
.story-grid article{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:34px;
  align-items:center;
  background:#fff;
  border:1px solid var(--line);
  border-radius:22px;
  overflow:hidden;
  box-shadow:0 10px 30px rgba(23,63,87,.055);
}
.story-grid article.reverse img{order:2}
.story-grid article > div{
  padding:var(--tb-space-xl);
  align-self:center;
}
.story-grid img{
  width:100%;
  height:350px;
  object-fit:cover;
}
.story-grid h2{
  margin:6px 0 var(--tb-space-sm);
  color:var(--navy);
  font-family:var(--font-display);
  font-size:32px;
  font-weight:600;
  letter-spacing:-.012em;
}
.story-grid a{font-weight:700;color:var(--navy)}

/* Beeldposities zijn inhoudelijk specifiek voor deze foto's. */
body.environment-page .omgeving-img-karakter{
  width:100%;
  object-fit:cover;
  object-position:center top;
}
body.environment-page .omgeving-img-vuurtoren{object-position:center 30%}
body.environment-page .omgeving-img-strand{object-position:center 52%}
body.environment-page .story-grid article > img:not(.omgeving-img-karakter):not(.omgeving-img-vuurtoren):not(.omgeving-img-strand),
body.environment-page .story-grid article.reverse > img:not(.omgeving-img-karakter):not(.omgeving-img-vuurtoren):not(.omgeving-img-strand){
  object-position:center center;
}

/* Sfeerbeeld tussen verhaal en activiteiten */
.texel-photo-break{
  position:relative;
  height:460px;
  padding:0;
  overflow:hidden;
}
.texel-photo-break > img{width:100%;height:100%;object-fit:cover}
.texel-photo-break::after{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(90deg,rgba(7,31,45,.35),transparent 65%);
}
.texel-photo-break > div{
  position:absolute;
  z-index:2;
  left:max(var(--tb-page-gutter),calc((100vw - var(--tb-container-main))/2));
  bottom:42px;
  max-width:650px;
  color:#fff;
  font-family:var(--font-display);
  font-size:clamp(28px,4vw,48px);
  font-weight:600;
  text-shadow:0 3px 20px rgba(0,0,0,.3);
}

/* Activiteitenkaarten: deze grid wordt alleen op Omgeving gebruikt. */
.rich-info-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:20px;
  align-items:stretch;
}
.rich-info-grid .info-card{height:100%;box-sizing:border-box}
.rich-environment .section-head{align-items:end}
.rich-environment .info-card{overflow:hidden}
.mini-landscape,
.rich-environment .environment-card-image{
  display:block;
  width:100%;
  height:190px;
  object-fit:cover;
}
.mini-landscape{
  border-radius:12px;
  margin-top:18px;
}
.season-card img{margin-top:var(--tb-space-sm);border-radius:12px}
.rich-environment .environment-card-image{
  width:calc(100% + var(--tb-space-xl));
  max-width:none;
  margin:14px calc(-1 * var(--tb-space-md)) 18px;
  border-radius:0;
  box-shadow:inset 0 -1px 0 rgba(255,255,255,.22);
  filter:saturate(.94) contrast(1.03);
  transition:transform .35s ease,filter .35s ease;
}
.rich-environment .info-card:hover .environment-card-image{
  transform:scale(1.025);
  filter:saturate(1) contrast(1.04);
}
.rich-environment .v13-environment-grid{align-items:stretch}
.rich-environment .v13-environment-grid .info-card{
  height:100%;
  display:flex;
  flex-direction:column;
  align-self:stretch;
  box-sizing:border-box;
}
.rich-environment .v13-environment-grid .info-card > strong{
  display:block;
  min-height:2.7em;
  line-height:1.35;
}
.rich-environment .v13-environment-grid .environment-card-image{
  flex:0 0 190px;
  height:190px;
}
.rich-environment .v13-environment-grid .info-card > span{display:block}
.rich-environment .v13-environment-grid .inline-links{
  margin-top:auto;
  padding-top:14px;
}

/* Werkelijke eindwaarden van de oude witruimte-fixes, nu op één plek. */
body.environment-page section.content:has(.environment-intro-card){padding-bottom:18px}
body.environment-page section.soft.content:has(.story-grid){
  padding-top:18px;
  padding-bottom:36px;
}
body.environment-page section.soft.content:has(.story-grid) + section.texel-photo-break{margin-top:0}
body.environment-page .texel-photo-break + .rich-environment{padding-top:44px}
body.environment-page .rich-environment{padding-bottom:28px}
body.environment-page .rich-environment + section.soft.content{
  padding-top:28px;
  padding-bottom:44px;
}

/* Tablet / kleiner desktop */
@media(max-width:900px){
  .environment-intro,
  .story-grid article{grid-template-columns:1fr}
  .story-grid article.reverse img{order:0}
  .environment-intro-card > div{padding:28px}
  .environment-intro-card > img{
    min-height:0;
    height:auto;
    aspect-ratio:3/2;
  }
  body.environment-page section.content:has(.environment-intro-card){padding-bottom:14px}
  body.environment-page section.soft.content:has(.story-grid){padding-top:14px}
}

/* Telefoon / smalle tablet */
@media(max-width:760px){

  body.environment-page .environment-intro-card,
  body.environment-page .story-grid article,
  body.environment-page .story-grid article.reverse{
    display:flex;
    flex-direction:column;
  }
  body.environment-page .environment-intro-card > img,
  body.environment-page .story-grid article > img,
  body.environment-page .story-grid article.reverse > img{
    order:1;
    width:100%;
    height:auto;
    min-height:0;
    object-fit:cover;
  }
  body.environment-page .environment-intro-card > div,
  body.environment-page .story-grid article > div,
  body.environment-page .story-grid article.reverse > div{order:2}

  body.environment-page .story-grid{gap:14px}
  body.environment-page .story-grid article{min-height:0;overflow:hidden}
  body.environment-page .story-grid article > img,
  body.environment-page .story-grid article.reverse > img{aspect-ratio:16/10}
  body.environment-page .story-grid article > img.omgeving-img-karakter,
  body.environment-page .story-grid article.reverse > img.omgeving-img-karakter{
    aspect-ratio:4/3;
    object-position:center top;
  }
  body.environment-page .story-grid article > img.omgeving-img-vuurtoren,
  body.environment-page .story-grid article.reverse > img.omgeving-img-vuurtoren{
    object-position:center 30%;
  }
  body.environment-page .story-grid article > img.omgeving-img-strand,
  body.environment-page .story-grid article.reverse > img.omgeving-img-strand{
    aspect-ratio:16/9;
    object-position:center 52%;
  }
  body.environment-page .environment-intro-card > img.omgeving-img-strand{
    aspect-ratio:16/9;
    object-position:center 52%;
  }

  body.environment-page .texel-photo-break,
  body.environment-page .texel-photo-break > div{
    height:280px;
    min-height:280px;
  }
  body.environment-page .texel-photo-break > div{
    display:flex;
    align-items:flex-end;
    padding:var(--tb-space-lg) 6vw;
  }

  body.environment-page .rich-environment{padding-top:22px}
  body.environment-page .rich-environment .section-head{margin-bottom:14px}
  body.environment-page .rich-environment .section-head h2{margin-bottom:6px}
  body.environment-page .rich-environment .section-head > p{margin-top:0}
  body.environment-page .rich-environment .v13-environment-grid{
    display:grid;
    grid-template-columns:1fr;
    gap:var(--tb-space-xs);
    overflow:visible;
    scroll-snap-type:none;
    overscroll-behavior:auto;
    padding:0;
  }
  body.environment-page .rich-environment .v13-environment-grid .info-card{
    width:auto;
    max-width:none;
    height:auto;
    min-height:0;
    padding:14px;
  }
  body.environment-page .rich-environment .v13-environment-grid .info-card > strong{min-height:0}
  body.environment-page .rich-environment .v13-environment-grid .environment-card-image{
    width:calc(100% + 28px);
    flex:0 0 142px;
    height:142px;
    margin:9px -14px 10px;
  }
  body.environment-page .rich-environment .v13-environment-grid .inline-links{
    margin-top:7px;
    padding-top:0;
  }
  body.environment-page .rich-environment + section.soft.content .center-cta{gap:14px}
}

/* Mobiel: de latere Fix50-eindwaarden behouden, zonder !important. */
@media(max-width:700px){
  body.environment-page section.soft.content:has(.story-grid){padding-bottom:28px}
  body.environment-page .texel-photo-break + .rich-environment{padding-top:34px}
  body.environment-page .rich-environment{padding-bottom:24px}
  body.environment-page .rich-environment + section.soft.content{
    padding-top:24px;
    padding-bottom:34px;
  }
}

@media(max-width:600px){
  .environment-intro-card{border-radius:14px}
  .environment-intro-card > div{padding:var(--tb-space-lg) 20px}
}

@media(max-width:560px){
  body.environment-page .story-grid article > div{padding:var(--tb-space-lg)}
  body.environment-page .texel-photo-break > div{
    left:5vw;
    right:5vw;
    bottom:28px;
  }
}

/* Telefoon liggend / laag scherm:
   geen aparte layoutwissel nodig. De breedte-breakpoints hierboven blijven
   leidend; alleen het grote sfeerbeeld wordt iets lager zodat verticale
   schermruimte niet onnodig wordt opgeslokt. */
@media(orientation:landscape) and (max-height:500px) and (max-width:900px){
  body.environment-page .texel-photo-break,
  body.environment-page .texel-photo-break > div{
    height:240px;
    min-height:240px;
  }
}

@media(prefers-reduced-motion:reduce){
  .rich-environment .environment-card-image{transition:none}
  .rich-environment .info-card:hover .environment-card-image{transform:none}
}
