/* ==========================================================================
   Crystal Room Innovation® – Stylesheet
   ========================================================================== */

:root{
  --navy:        #0A1628;
  --navy-2:      #132A45;
  --cyan:        #3FD4FF;
  --steel:       #5B8FB0;
  --white:       #FFFFFF;
  --ink:         #1A2634;
  --paper:       #F4F7FA;
  --line:        #C7D3DE;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --header-h: 76px;
  --header-h-mobile: 62px;

  --container: 1120px;
}

*, *::before, *::after{ box-sizing:border-box; -webkit-tap-highlight-color:transparent; }

html{
  scroll-behavior:smooth;
  overflow-x:clip;
  width:100%;
}

body{
  margin:0;
  font-family:var(--font);
  color:var(--ink);
  background:var(--white);
  font-size:16px;
  line-height:1.7;
  -webkit-font-smoothing:antialiased;
  overflow-x:clip;
  width:100%;
}

img{ max-width:100%; display:block; }

a{ color:inherit; text-decoration:none; -webkit-tap-highlight-color:transparent; }

.container{
  max-width:var(--container);
  margin:0 auto;
  padding:0 28px;
}

section[id]{
  scroll-margin-top: calc(var(--header-h) + 20px);
}

/* ---------- Header ---------- */

.site-header{
  position:sticky;
  top:0;
  z-index:200;
  height:var(--header-h);
  background:rgba(10,22,40,0.92);
  backdrop-filter:saturate(140%) blur(8px);
  -webkit-backdrop-filter:saturate(140%) blur(8px);
  border-bottom:1px solid rgba(255,255,255,0.08);
}

.header-inner{
  position:relative;
  max-width:var(--container);
  margin:0 auto;
  height:100%;
  padding:0 28px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:24px;
}

.brand{
  color:var(--white);
  font-weight:700;
  font-size:1rem;
  letter-spacing:0.02em;
  white-space:nowrap;
}
.brand sup{ font-size:0.55em; }

.main-nav{
  display:flex;
  align-items:center;
  gap:8px;
}

.main-nav ul{
  list-style:none;
  display:flex;
  align-items:center;
  gap:6px;
  margin:0;
  padding:0;
}

.main-nav > ul > li{
  position:static;
}

.nav-link{
  display:flex;
  align-items:center;
  gap:5px;
  padding:10px 14px;
  font-size:0.92rem;
  font-weight:500;
  color:rgba(255,255,255,0.85);
  border-radius:4px;
  transition:color .2s ease, background-color .2s ease;
  background:none;
  border:none;
  cursor:pointer;
  font-family:inherit;
}

.nav-link:hover,
.nav-link:focus-visible{
  color:var(--cyan);
  background:rgba(255,255,255,0.06);
}

.nav-link .caret{
  width:8px;height:8px;
  border-right:1.5px solid currentColor;
  border-bottom:1.5px solid currentColor;
  transform:rotate(45deg);
  margin-top:-3px;
  transition:transform .2s ease;
}
.has-dropdown.open .nav-link .caret{
  transform:rotate(225deg);
  margin-top:3px;
}

.dropdown{
  list-style:none;
  margin:0;
  padding:16px;
  position:absolute;
  top:calc(100% + 8px);
  left:0;
  right:0;
  display:grid;
  grid-template-columns:repeat(2, 1fr);
  gap:2px 16px;
  background:rgba(19,42,69,0.92);
  backdrop-filter:blur(12px) saturate(150%);
  -webkit-backdrop-filter:blur(12px) saturate(150%);
  border:1px solid rgba(255,255,255,0.1);
  border-radius:10px;
  box-shadow:0 18px 40px rgba(0,0,0,0.35);
  opacity:0;
  visibility:hidden;
  transform:translateY(-6px);
  transition:opacity .18s ease, transform .18s ease, visibility .18s;
}

.has-dropdown.open .dropdown,
.has-dropdown:hover .dropdown{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}

.dropdown li a{
  display:block;
  padding:10px 14px;
  font-size:0.9rem;
  color:rgba(255,255,255,0.85);
  border-radius:6px;
  transition:background-color .15s ease, color .15s ease;
}
.dropdown li a:hover,
.dropdown li a:focus-visible{
  background:rgba(63,212,255,0.12);
  color:var(--cyan);
}

.lang-switch{
  display:flex;
  align-items:center;
  gap:6px;
  font-size:0.82rem;
  font-weight:600;
  letter-spacing:0.03em;
  color:rgba(255,255,255,0.55);
  margin-right:4px;
}
.lang-switch a,
.lang-switch span{
  padding:3px 6px;
  border-radius:4px;
}
.lang-switch .is-current{
  color:var(--white);
  background:rgba(255,255,255,0.1);
}
.lang-switch a:hover{
  color:var(--cyan);
}
.lang-divider{ opacity:0.4; }

.burger{
  display:none;
  width:40px;
  height:40px;
  border:none;
  background:transparent;
  cursor:pointer;
  padding:0;
  position:relative;
}
.burger span,
.burger span::before,
.burger span::after{
  content:'';
  position:absolute;
  left:8px;
  right:8px;
  height:2px;
  background:var(--white);
  transition:transform .2s ease, opacity .2s ease, top .2s ease;
}
.burger span{ top:19px; }
.burger span::before{ top:-7px; }
.burger span::after{ top:7px; }
.burger.open span{ background:transparent; }
.burger.open span::before{ transform:rotate(45deg); top:0; }
.burger.open span::after{ transform:rotate(-45deg); top:0; }

/* ---------- Hero ---------- */

.hero{
  position:relative;
  width:100%;
  background:var(--navy);
  line-height:0;
}

.hero-media{ display:block; }
.hero-img{
  width:100%;
  height:auto;
  display:block;
}

.hero-overlay{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
}

.hero-inner{
  max-width:var(--container);
  width:100%;
  margin:0 auto;
  padding:0 28px;
  line-height:1.7;
}

.hero h1{
  color:var(--white);
  font-weight:800;
  font-size:clamp(1.6rem, 5.2vw, 5.2rem);
  line-height:1.02;
  letter-spacing:-0.01em;
  max-width:11ch;
  margin:0;
  text-shadow:0 4px 30px rgba(0,0,0,0.45);
}
.hero h1 sup{
  font-size:0.35em;
  top:-0.6em;
}

@media (max-width:768px){
  .hero-overlay{
    align-items:flex-end;
  }
  .hero-inner{
    padding-bottom:9%;
    background:linear-gradient(to top, rgba(10,22,40,0.55) 0%, rgba(10,22,40,0) 65%);
    padding-top:18%;
  }
}

/* ---------- Content sections ---------- */

main{
  background:var(--white);
}

.section{
  padding:56px 0;
}
.section--alt{
  background:var(--paper);
}

@media (max-width:640px){
  .section{ padding:40px 0; }
}

.page-title{
  font-size:clamp(1.6rem, 2.3vw + 1rem, 2.6rem);
  font-weight:700;
  color:var(--navy);
  line-height:1.3;
  max-width:none;
  text-wrap:balance;
  margin:0 0 12px;
}

.page-title-rule{
  width:64px;
  height:3px;
  background:var(--cyan);
  border:none;
  margin:0 0 32px;
}

.section-title{
  font-size:clamp(1.25rem, 0.6vw + 1.1rem, 1.5rem);
  font-weight:700;
  color:var(--navy);
  margin:0 0 22px;
  display:flex;
  align-items:center;
  gap:14px;
}
.section-title::before{
  content:'';
  width:10px;
  height:10px;
  border-radius:50%;
  background:var(--cyan);
  flex:none;
}

.sub-title{
  font-size:1.08rem;
  font-weight:700;
  color:var(--steel);
  text-transform:uppercase;
  letter-spacing:0.04em;
  margin:28px 0 12px;
}
.sub-title:first-of-type{ margin-top:8px; }

.prose{
  max-width:74ch;
}
.prose p{
  margin:0 0 20px;
  color:var(--ink);
}
.prose p:last-child{ margin-bottom:0; }

.flow-root{ display:flow-root; }

/* Floated images with wrapping text (used for all inline figures) */
.wrap-figure{
  max-width:300px;
  margin:6px 0 24px 32px;
  float:right;
  position:relative;
}
.wrap-figure--left{
  float:left;
  margin:6px 32px 24px 0;
}
.wrap-figure .zoom-wrap{
  overflow:visible;
  border-radius:6px;
  box-shadow:0 8px 24px rgba(10,22,40,0.18);
}
.wrap-figure img{
  border-radius:6px;
  transition:transform .4s cubic-bezier(.2,.8,.2,1), box-shadow .4s ease;
  transform-origin:center center;
  position:relative;
  z-index:1;
}
.wrap-figure--zoom .zoom-wrap{ cursor:zoom-in; }
.wrap-figure--zoom:hover img,
.wrap-figure--zoom.is-zoomed img{
  transform:scale(2.65);
  z-index:50;
  box-shadow:0 30px 70px rgba(10,22,40,0.45);
}
.wrap-figure figcaption{
  font-size:0.78rem;
  font-style:italic;
  color:var(--steel);
  margin-top:8px;
}

@media (max-width:640px){
  .wrap-figure{
    float:none;
    max-width:340px;
    margin:0 auto 28px;
  }
  .wrap-figure--zoom:hover img,
  .wrap-figure--zoom.is-zoomed img{
    transform:scale(1.9);
  }
}

/* Full-bleed images: simple 100%-width blocks placed outside .container,
   so they always match the true viewport width without vw-related
   scrollbar offset issues */
.full-bleed{
  width:100%;
}
.full-bleed img{ width:100%; height:auto; display:block; }

.full-bleed-wrap{
  margin:48px 0;
}

/* ---------- Belt cards ---------- */
.belt-block + .belt-block{
  margin-top:32px;
  padding-top:32px;
  border-top:1px solid var(--line);
}

/* ---------- Footer ---------- */

.site-footer{
  background:var(--navy);
  color:rgba(255,255,255,0.7);
  padding:36px 0;
  font-size:0.86rem;
}
.footer-inner{
  max-width:var(--container);
  margin:0 auto;
  padding:0 28px;
  display:flex;
  flex-wrap:wrap;
  gap:12px 24px;
  align-items:center;
  justify-content:space-between;
}
.footer-inner a:hover{ color:var(--cyan); }
.footer-links{
  display:flex;
  gap:18px;
  align-items:center;
}
.footer-dot{ opacity:0.4; }

/* ---------- Reveal on scroll ---------- */
.reveal{
  opacity:0;
  transform:translateY(22px);
  transition:opacity .7s ease, transform .7s ease;
}
.reveal.is-visible{
  opacity:1;
  transform:translateY(0);
}

@media (prefers-reduced-motion:reduce){
  .reveal{ opacity:1; transform:none; transition:none; }
  html{ scroll-behavior:auto; }
}

/* ---------- Impressum page ---------- */
.impressum-hero{
  background:var(--navy);
  padding:70px 0 50px;
}
.impressum-hero h1{
  color:var(--white);
  font-size:clamp(1.8rem,2vw + 1rem,2.6rem);
  font-weight:800;
  margin:0;
}
.impressum-hero .back-link{
  display:inline-flex;
  align-items:center;
  gap:8px;
  color:var(--cyan);
  font-size:0.9rem;
  font-weight:600;
  margin-bottom:22px;
}
.impressum-hero .back-link::before{
  content:'';
  width:7px;height:7px;
  border-left:2px solid currentColor;
  border-bottom:2px solid currentColor;
  transform:rotate(45deg);
}

.imp-block + .imp-block{
  margin-top:36px;
  padding-top:36px;
  border-top:1px solid var(--line);
}
.imp-block h2{
  font-size:1.15rem;
  color:var(--navy);
  margin:0 0 14px;
}
.imp-block p{ margin:0 0 8px; }
.imp-block ul{ margin:0 0 8px; padding-left:20px; }

/* ---------- Responsive nav ---------- */
@media (max-width:880px){
  .burger{ display:block; }

  .header-inner{ position:relative; }

  .main-nav{
    position:absolute;
    top:100%;
    left:0;
    right:0;
    z-index:5;
    background:rgba(10,22,40,0.85);
    backdrop-filter:blur(14px) saturate(150%);
    -webkit-backdrop-filter:blur(14px) saturate(150%);
    flex-direction:column;
    align-items:stretch;
    padding:8px 20px 20px;
    max-height:calc(100vh - var(--header-h-mobile) - 10px);
    overflow-y:auto;
    box-shadow:0 20px 40px rgba(0,0,0,0.35);
    opacity:0;
    visibility:hidden;
    pointer-events:none;
    transform:translateY(-8px);
    transition:opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .main-nav.open{
    opacity:1;
    visibility:visible;
    pointer-events:auto;
    transform:translateY(0);
  }

  .main-nav ul{
    flex-direction:column;
    align-items:stretch;
    width:100%;
    gap:0;
  }
  .nav-link{
    width:100%;
    justify-content:space-between;
    padding:16px 6px;
    font-size:1rem;
    border-bottom:1px solid rgba(255,255,255,0.08);
    border-radius:0;
  }
  .dropdown{
    position:static;
    display:none;
    grid-template-columns:1fr;
    box-shadow:none;
    border:none;
    background:rgba(255,255,255,0.04);
    opacity:1;
    visibility:visible;
    transform:none;
    padding:6px;
    margin:0 0 8px;
  }
  .has-dropdown.open .dropdown{ display:grid; }

  .lang-switch{
    order:-1;
    margin:4px 0 14px;
    font-size:0.9rem;
  }

  .site-header{ height:var(--header-h-mobile); }
  .header-inner{ padding:0 20px; }

  :root{ --header-h: var(--header-h-mobile); }
}

@media (min-width:881px){
  .has-dropdown:hover .dropdown{
    opacity:1; visibility:visible; transform:translateY(0);
  }
}
