/* ===== BalliesReef 3D-modus =====
   Alles hieronder werkt alleen als <html class="has-3d"> (WebGL beschikbaar; zie js/reef3d.js).
   Zonder WebGL blijft het gewone ontwerp uit style.css staan. */

#reef3d{position:fixed;inset:0;width:100%;height:100%;z-index:0;pointer-events:none;display:none}
html.has-3d #reef3d{display:block}

html.has-3d{--glass:linear-gradient(160deg,rgba(255,255,255,.11),rgba(255,255,255,.04));--glass-line:rgba(190,240,245,.2);--glass-shadow:0 18px 50px rgba(0,8,16,.32),inset 0 1px 0 rgba(255,255,255,.14);--radius:28px}
html.has-3d body{background:linear-gradient(180deg,#0f7288 0%,#08475f 34%,#061b2b 100%) fixed}
html.has-3d body::before{content:"";position:fixed;inset:0;z-index:-1;background:#020b13;opacity:calc(var(--depth,0) * .82);pointer-events:none}
html.has-3d main,html.has-3d .footer{position:relative;z-index:1}

/* zwevende navigatie */
html.has-3d .site-header{top:12px;width:min(var(--max),calc(100% - 28px));margin:12px auto 0;border:1px solid var(--glass-line);border-radius:999px;background:rgba(6,27,43,.5);-webkit-backdrop-filter:blur(16px) saturate(1.3);backdrop-filter:blur(16px) saturate(1.3);box-shadow:0 10px 40px rgba(0,8,16,.28)}
html.has-3d .site-header .wrap{width:100%;padding-inline:clamp(16px,3vw,28px)}
html.has-3d .nav{min-height:62px}
html.has-3d .nav-links .facebook{background:rgba(121,227,211,.1)}

/* hero: geen doos, tekst op het water en de foto als gloeiend venster */
html.has-3d .hero{padding:clamp(24px,6vh,64px) 0 clamp(48px,12vh,130px)}
html.has-3d .hero-frame{min-height:min(74vh,620px);display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,.92fr);align-items:center;gap:clamp(24px,4vw,64px);background:none;border:0;border-radius:0;overflow:visible}
html.has-3d .hero-frame:after{display:none}
html.has-3d .hero-frame>img{position:relative;inset:auto;order:2;width:100%;height:auto;aspect-ratio:709/264;opacity:1;object-fit:cover;border-radius:clamp(36px,6vw,90px);box-shadow:0 0 0 1px rgba(121,227,211,.38),0 0 70px rgba(121,227,211,.28),0 30px 80px rgba(0,8,16,.5);animation:float 7s ease-in-out infinite}
html.has-3d .hero-copy{order:1;max-width:none;padding:0}
html.has-3d .hero h1{font-size:clamp(2.6rem,6.2vw,5.4rem);text-shadow:0 4px 40px rgba(2,11,19,.55)}
html.has-3d .hero .lead{text-shadow:0 2px 20px rgba(2,11,19,.6)}
html.has-3d .quick-facts{gap:12px}
html.has-3d .quick-facts>div{padding:10px 18px;border:1px solid var(--glass-line);border-radius:20px;background:var(--glass);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}
html.has-3d .button.primary{box-shadow:0 0 0 0 rgba(121,227,211,.5),0 10px 30px rgba(121,227,211,.25);transition:transform .2s,box-shadow .2s}
html.has-3d .button:hover{transform:translateY(-2px);filter:none}
html.has-3d .button.secondary{background:rgba(255,255,255,.06);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}
.dive-hint{margin:30px 0 0;color:#cdeff3;font-size:.9rem;letter-spacing:.05em;animation:dive 2.4s ease-in-out infinite}

/* secties en titels */
html.has-3d .section{padding:clamp(56px,11vh,130px) 0}
html.has-3d .section-heading{margin-bottom:clamp(24px,4vh,44px)}
html.has-3d .section-heading h2,html.has-3d .page-heading h1{text-shadow:0 4px 34px rgba(2,11,19,.6)}
html.has-3d .section-heading h2{font-size:clamp(2.1rem,4.6vw,3.6rem)}
html.has-3d .page-heading{padding-top:clamp(48px,10vh,110px)}
html.has-3d .page-heading p,html.has-3d .section-heading p{color:#cfe6ea;text-shadow:0 2px 16px rgba(2,11,19,.6)}

/* glas in plaats van dozen */
html.has-3d .panel,html.has-3d .blog-card,html.has-3d .article,html.has-3d .photo-card,html.has-3d .feature-callout,html.has-3d .fact{background:var(--glass);border:1px solid var(--glass-line);border-radius:var(--radius);box-shadow:var(--glass-shadow);-webkit-backdrop-filter:blur(14px) saturate(1.25);backdrop-filter:blur(14px) saturate(1.25)}
html.has-3d .fact{border-radius:20px;box-shadow:none}
html.has-3d .tag{background:rgba(121,227,211,.08);border-color:rgba(121,227,211,.32)}
html.has-3d .blog-card,html.has-3d .photo-card{overflow:hidden;transition:transform .35s cubic-bezier(.2,.8,.2,1),box-shadow .35s}
html.has-3d .blog-card:hover,html.has-3d .photo-card:hover{transform:translateY(-8px);box-shadow:0 26px 60px rgba(0,8,16,.4),inset 0 1px 0 rgba(255,255,255,.18)}
html.has-3d .blog-card img,html.has-3d .photo-card img{transition:transform .6s}
html.has-3d .blog-card:hover img,html.has-3d .photo-card:hover img{transform:scale(1.05)}
html.has-3d .blog-content{padding:22px 22px 24px}
html.has-3d .feature-callout{border-radius:40px;padding:clamp(26px,4vw,48px);background:linear-gradient(120deg,rgba(121,227,211,.18),rgba(255,255,255,.05));box-shadow:0 0 70px rgba(121,227,211,.14),var(--glass-shadow)}
html.has-3d .article{padding:clamp(22px,3vw,34px)}
html.has-3d .values td{border-bottom-color:rgba(190,240,245,.16)}

/* golvende ritmiek: kaarten staan niet in een strak rooster */
@media (min-width:860px){
  html.has-3d .blog-grid .blog-card:nth-child(2){margin-top:36px}
  html.has-3d .blog-grid .blog-card:nth-child(3){margin-top:12px}
  html.has-3d .intro-grid .panel:nth-child(2){margin-top:40px}
  html.has-3d .photo-grid .photo-card:nth-child(3n+2){margin-top:34px}
  html.has-3d .two-col>.panel:nth-child(2){margin-top:34px}
}

/* voet = zeebodem */
html.has-3d .footer{margin-top:0;padding:clamp(28px,5vh,56px) 0 22px;border-top:0;background:linear-gradient(180deg,transparent,rgba(2,11,19,.62) 60%);color:#b9d3d9}

/* dieptemeter */
.depth-gauge{position:fixed;right:clamp(10px,2vw,26px);top:50%;z-index:5;transform:translateY(-50%);display:none;flex-direction:column;align-items:center;gap:8px;pointer-events:none;color:#cdeff3;font-size:.72rem;letter-spacing:.08em}
.depth-gauge .dg-track{position:relative;width:2px;height:min(34vh,260px);background:rgba(190,240,245,.25);border-radius:2px}
.depth-gauge .dg-dot{position:absolute;left:50%;top:0;width:12px;height:12px;margin-left:-6px;border-radius:50%;background:#79e3d3;box-shadow:0 0 14px rgba(121,227,211,.9)}
.depth-gauge .dg-val{padding:3px 9px;border:1px solid var(--glass-line,rgba(190,240,245,.2));border-radius:999px;background:rgba(6,27,43,.5);font-variant-numeric:tabular-nums}
html.has-3d .depth-gauge{display:flex}

/* verschijnen bij scrollen (alleen als JS dit aanzet en beweging is toegestaan) */
html.js-reveal .reveal{transition:opacity .8s ease,translate .8s cubic-bezier(.2,.8,.2,1)}
html.js-reveal .reveal:not(.in){opacity:0;translate:0 28px}

@keyframes float{0%,100%{transform:translateY(0)}50%{transform:translateY(-10px)}}
@keyframes dive{0%,100%{transform:translateY(0);opacity:.7}50%{transform:translateY(5px);opacity:1}}

/* tablet en telefoon */
@media (max-width:900px){
  html.has-3d .hero-frame{grid-template-columns:1fr;min-height:0;gap:28px}
  html.has-3d .hero-frame>img{order:2;border-radius:48px}
  .depth-gauge{display:none!important}
}
@media (max-width:700px){
  html.has-3d .site-header{top:8px;margin-top:8px;border-radius:26px}
  html.has-3d .nav-links{background:rgba(6,27,43,.92);border-radius:22px;top:62px;left:0;right:0}
  html.has-3d .hero{padding-top:18px}
  html.has-3d .quick-facts>div{padding:8px 14px}
  /* minder zware effecten op telefoons: batterij en vloeiendheid */
  html.has-3d .panel,html.has-3d .blog-card,html.has-3d .article,html.has-3d .photo-card,html.has-3d .feature-callout,html.has-3d .fact{-webkit-backdrop-filter:none;backdrop-filter:none;background:linear-gradient(160deg,rgba(14,48,68,.78),rgba(8,32,48,.7))}
  html.has-3d .hero-frame>img{animation:none}
}
@media (prefers-reduced-motion:reduce){
  .dive-hint,html.has-3d .hero-frame>img{animation:none}
  html.js-reveal .reveal{transition:none}
  html.js-reveal .reveal:not(.in){opacity:1;translate:none}
  html.has-3d .blog-card:hover,html.has-3d .photo-card:hover{transform:none}
}

/* ===== Typografie en vormgeving zoals in de 3D-voorbeeldvideo =====
   Grote, vette, strakke koppen met één sierlijk schuin accentwoord; tekst staat direct op het water. */
html.has-3d{--sans:"Inter","Segoe UI Variable Display","Segoe UI","Helvetica Neue",Arial,system-ui,sans-serif;--serif:"Instrument Serif","Playfair Display",Georgia,"Times New Roman",serif}
html.has-3d body{font-family:var(--sans)}
html.has-3d .hero h1,html.has-3d .page-heading h1,html.has-3d .section-heading h2,html.has-3d .feature-callout h2,html.has-3d .panel h2,html.has-3d .article h2,html.has-3d .blog-card h3{font-family:var(--sans);font-weight:700;letter-spacing:-.04em;line-height:1}
html.has-3d .hero h1{font-size:clamp(2.9rem,7.6vw,6.6rem);line-height:.96;max-width:12ch;margin-bottom:22px}
html.has-3d .page-heading h1{font-size:clamp(2.8rem,7vw,5.8rem)}
html.has-3d .section-heading h2{font-size:clamp(2.3rem,5.4vw,4.4rem)}
html.has-3d .feature-callout h2{font-size:clamp(1.9rem,3.6vw,3rem)}
html.has-3d .panel h2,html.has-3d .article h2{font-size:clamp(1.6rem,2.6vw,2.2rem);letter-spacing:-.03em}
html.has-3d .blog-card h3{font-size:1.5rem;letter-spacing:-.025em;line-height:1.08}
html.has-3d .panel h3{font-size:1.35rem;letter-spacing:-.02em;font-weight:650}
html.has-3d h1 em,html.has-3d h2 em{font-family:var(--serif);font-style:italic;font-weight:400;letter-spacing:-.01em;color:#8fe9db;padding-right:.04em}
html.has-3d .eyebrow{font-weight:600;letter-spacing:.2em;color:#8fe9db}
html.has-3d .hero .lead,html.has-3d .page-heading p,html.has-3d .section-heading p{font-size:clamp(1rem,1.5vw,1.2rem);line-height:1.55;font-weight:400;color:rgba(235,248,250,.82);max-width:34rem}
html.has-3d .button{font-family:var(--sans);font-weight:600;letter-spacing:-.005em}

/* minder dozen: tekst op het water, alleen foto's en de oproep behouden glas */
html.has-3d .panel:not(.contact-card),html.has-3d .article,html.has-3d .fact{background:none;border:0;border-top:1px solid rgba(190,240,245,.28);border-radius:0;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none;padding:22px 2px 6px}
html.has-3d .panel:not(.contact-card) p,html.has-3d .article p,html.has-3d .panel li{color:rgba(235,248,250,.86);text-shadow:0 1px 14px rgba(2,11,19,.55)}
html.has-3d .fact{border-top-color:rgba(190,240,245,.2);padding:14px 2px 4px}
html.has-3d .blog-card{border-radius:30px}
html.has-3d .blog-card .category,html.has-3d .article .category{letter-spacing:.16em}
html.has-3d .intro-grid,html.has-3d .two-col{gap:clamp(28px,5vw,72px)}
html.has-3d .article-list{gap:clamp(30px,5vw,56px)}
html.has-3d .nav-links a{font-weight:500}
@media (max-width:700px){
  html.has-3d .hero h1{font-size:clamp(2.6rem,13vw,3.6rem);max-width:none}
  html.has-3d .panel:not(.contact-card),html.has-3d .article{background:none}
}
html.has-3d .hero h1{font-size:clamp(2.7rem,6.2vw,6.2rem)}
html.has-3d .hero h1 em{display:inline-block;white-space:nowrap}
@media (min-width:901px){html.has-3d .hero-frame{grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr)}}

/* de 3D-wereld verschijnt zacht zodra de modellen geladen zijn */
html.has-3d #reef3d{opacity:0;transition:opacity 1.4s ease}
html.has-3d.reef-ready #reef3d{opacity:1}
html.has-3d .credits{padding:6px 0 18px;font-size:.78rem;line-height:1.5;color:rgba(185,211,217,.75)}
html.has-3d .credits a{color:#8fe9db}

/* ===== Afwerking: ritme, glans en 3D-gevoel ===== */
html.has-3d main{counter-reset:sec}
html.has-3d .section-heading h2::before{counter-increment:sec;content:counter(sec,decimal-leading-zero) " \2014  rif";display:block;margin-bottom:14px;font:600 .78rem/1 var(--sans);letter-spacing:.24em;text-transform:uppercase;color:#8fe9db;text-shadow:none}
html.has-3d .photo-grid,html.has-3d .blog-grid{align-items:start}
html.has-3d .blog-card img,html.has-3d .photo-card img{aspect-ratio:4/3;width:100%;object-fit:cover}
html.has-3d .photo-card{padding:0;line-height:0}

/* glans die met je muis meebeweegt over glazen kaarten */
html.has-3d .blog-card,html.has-3d .photo-card,html.has-3d .feature-callout,html.has-3d .contact-card{background:radial-gradient(420px circle at var(--mx,50%) var(--my,0%),rgba(121,227,211,0) 0,transparent 60%),var(--glass)}
html.has-3d .blog-card:hover,html.has-3d .photo-card:hover,html.has-3d .feature-callout:hover,html.has-3d .contact-card:hover{background:radial-gradient(420px circle at var(--mx,50%) var(--my,0%),rgba(121,227,211,.2),transparent 62%),var(--glass)}
html.has-3d .tilt{transform-style:preserve-3d;will-change:transform}
html.has-3d .tilt.tilting{transition:transform .08s linear}

/* navigatie: duidelijke huidige pagina */
html.has-3d .nav-links a{position:relative}
html.has-3d .nav-links a:not(.facebook)::after{content:"";position:absolute;left:50%;bottom:-8px;width:5px;height:5px;margin-left:-2.5px;border-radius:50%;background:#79e3d3;box-shadow:0 0 10px #79e3d3;opacity:0;transform:scale(.4);transition:.25s}
html.has-3d .nav-links a[aria-current=page]::after{opacity:1;transform:scale(1)}
html.has-3d .brand{letter-spacing:-.02em}

/* toetsenbordfocus altijd zichtbaar */
html.has-3d a:focus-visible,html.has-3d button:focus-visible,html.has-3d summary:focus-visible{outline:2px solid #79e3d3;outline-offset:3px;border-radius:8px}

/* footer: drie kolommen */
html.has-3d .footer-grid{display:grid;grid-template-columns:1.3fr 1fr 1fr;gap:clamp(24px,4vw,64px);padding:8px 0 26px}
html.has-3d .footer-grid strong{display:block;margin-bottom:10px;color:#eaf8f7;font-size:.78rem;letter-spacing:.2em;text-transform:uppercase;font-weight:600}
html.has-3d .footer-grid a{display:block;padding:3px 0;color:#b9d3d9;text-decoration:none}
html.has-3d .footer-grid a:hover{color:#8fe9db}
html.has-3d .footer-grid p{margin:8px 0 0;color:#9ebfc6;max-width:26ch}
html.has-3d .footer-grid .brand{display:inline-block;font-size:1.3rem;color:#fff}
html.has-3d .footer-grid .brand span{color:#79e3d3}
html.has-3d .legal{padding:14px 0 6px;border-top:1px solid rgba(190,240,245,.16);font-size:.8rem;color:#8fb0b8}
@media (max-width:700px){html.has-3d .footer-grid{grid-template-columns:1fr 1fr}html.has-3d .footer-grid>div:first-child{grid-column:1/-1}}

/* ===== Logo-foto (aquarium met neon "BalliesReef"): geheel in beeld, als glazen venster ===== */
html.has-3d .hero-frame>img{border-radius:26px;animation:none;translate:0 0;box-shadow:0 0 0 1px rgba(190,240,245,.45),0 0 0 9px rgba(255,255,255,.055),0 0 0 10px rgba(190,240,245,.16),0 0 90px rgba(121,227,211,.26),0 36px 80px rgba(0,8,16,.55);animation:floaty 7s ease-in-out infinite;transition:transform .15s linear}
@keyframes floaty{0%,100%{translate:0 0}50%{translate:0 -10px}}
html.has-3d .hero-frame{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
@media (min-width:1100px){html.has-3d .hero-frame{grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr)}}
@media (max-width:900px){html.has-3d .hero-frame>img{border-radius:20px;box-shadow:0 0 0 1px rgba(190,240,245,.4),0 0 0 7px rgba(255,255,255,.05),0 0 60px rgba(121,227,211,.22),0 24px 50px rgba(0,8,16,.5)}}
@media (prefers-reduced-motion:reduce){html.has-3d .hero-frame>img{animation:none}}
@media (max-width:1359px){.depth-gauge{display:none!important}}
@media (max-width:900px){html.has-3d .hero-frame{grid-template-columns:1fr;min-height:0;gap:28px}html.has-3d .hero-frame>img{max-width:560px;margin-inline:auto}}

/* Banner met echt logo (img/banner.jpg) en logo in menu en footer */
html.has-3d .hero-frame>img{aspect-ratio:922/352;object-fit:cover}
html.has-3d .brand img{height:38px}
html.has-3d .footer-grid .brand img{height:50px}
html.has-3d .aq-photo img{border-radius:26px;box-shadow:0 0 0 1px rgba(190,240,245,.4),0 0 0 8px rgba(255,255,255,.05),0 0 70px rgba(121,227,211,.2),0 28px 60px rgba(0,8,16,.45)}
html.has-3d .aq-photo{padding-block:8px 18px}
@media (max-width:700px){html.has-3d .brand img{height:32px}}

/* geen apart donker blok achter de hero-tekst op de telefoon: de tekst staat direct op het water */
html.has-3d .hero-copy{background:none}
