@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-size: cover;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    overflow-x: hidden; /* Prevent horizontal scroll */
}

header {
    z-index: 9999 !important;
    position: fixed !important;
    top: 0;
    left: 0;
}

#myVideo {
  position: fixed;
  right: 0;
  bottom: 0;
  min-width: 100%;
  min-height: 100%;
  z-index: -1;
  object-fit: cover; /* Better video scaling on all devices */
}

main {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  height: 100%;
  margin-top: 4rem;
  padding: 0 15px; /* Safe side padding on small screens */
}

.allcontent {    
    width: 100%;
    max-width: 950px;
    margin: 25px auto 50px;
    border: 1px solid #ddad5a;
    box-shadow: 0 0 0.55em #ffdea4, 0 0 0.55em #ffdea4, 0 0 0.55em #ddad5a;
    border-radius: 5px;
    overflow: hidden;
    background-color: transparent;
    backdrop-filter: blur(4px);
}

.container1 {
    width: 100%;
}

.banner {
    position: relative;
    background: url(../pics/electricity.jpg) no-repeat center;
    background-size: cover;
    height: 260px;           /* Good starting height */
    min-height: 180px;
}

.infowrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 15px;
}

.topframe {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 950px;
    min-width: unset;
    margin-top: 4px;
    margin-bottom: 25px;
    padding: 3px 20px 25px 20px;
    border-radius: 2px;
    /* box-shadow: 0 0 0.35em #ffdea4, 0 0 0.35em #ffdea4, 0 0 0.35em #ddad5a; */
}

.headline {
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Orbitron', 'Josefin Sans', 'Poppins', sans-serif;
    font-size: 40px;
    font-weight: 300;
    letter-spacing: 1px;
    text-align: center;
    text-transform: uppercase;
    color: #fff;
    text-shadow: 0 0 0.35em #7ae7e7, 0 0 0.35em #7ae7e7, 0 0 0.35em #1b2bae;    
    margin: 5px 0;
    line-height: 1.15;
    white-space: nowrap;
    max-width: 100%;
    min-width: 0;
    flex-shrink: 1;
    box-sizing: border-box;
}

.textmedia {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.textmedia p {
    width: 100%;
    max-width: 620px;
    font-family: 'josefin sans', 'poppins';
    font-size: clamp(18px, 4.5vw, 25px);
    /* font-size: 25px; */
    color: #fff;
    text-align: center;
    padding: 5px;
}

.textmedia2 {
    display: flex;
    justify-content: center;
    margin: 20px 0 15px;
    font-family: 'Josefin Sans', 'Poppins', sans-serif;
    font-size: clamp(22px, 5vw, 28px);
    color: #fff;
    text-align: center;
}

.picwrapper1 {
    display: flex;
    flex-direction: column;
    margin-bottom: 30px;
}

.bildtext,
.bildtext2 {
    display: flex;
    justify-content: center;
    margin: 12px 0 10px;
    font-family: 'Josefin Sans', 'Poppins', sans-serif;
    font-size: clamp(20px, 4.8vw, 25px);
    color: #fff;
    text-align: center;
}

.flexgrid {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

.flexgrid img {
    max-width: 100%;
    width: 850px;
    height: auto;
    border-radius: 4px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

/* ====================== MEDIA QUERIES ====================== */

/* Start shrinking when viewport is 720px or narrower */
@media (max-width: 820px) {
    .headline {
        font-size: calc(40px * (100vw / 820px));
        letter-spacing: calc(1px * (100vw / 820px));
        max-width: 100%;
        min-width: 0;
        flex-shrink: 1;
    }
}

/* Large screens - keep original desktop proportions */
@media (min-width: 1200px) {
    .allcontent {
        max-width: 975px;
    }
}