/* Fixed header and footer bar */
body { 
    margin:0; 
    padding:0; 
    font-family:sans-serif; 
    background:#f5f5f5; 
}

/* HEADER */
header { 
    position:fixed; 
    top:0; 
    left:0; 
    right:0; 
    background:#202020; 
    color:white; 
    height:60px; 
    display:flex; 
    align-items:center; 
    justify-content:space-between; 
    padding:0 15px; 
    z-index:1000; 
}
header h1 { 
    font-size:1.3em; 
    margin:0; 
}
header .lang img { 
    height:24px; 
}


/* FOOTER – 3 mezős reszponzív */
footer {
    position:fixed;
    bottom:0;
    left:0;
    right:0;
    background:#202020;
    color:white;
    padding:6px 10px;
    display:flex;
    flex-wrap:wrap;
    align-items:center;
    justify-content:space-between;
    font-size:0.9em;
    text-align:center;
    z-index:1000;
}

footer .f-left,
footer .f-center,
footer .f-right {
    flex:1;
    padding:2px 5px;
}

/* Mobil: minden sor külön blokk */
@media (max-width: 600px) {
    footer {
        flex-direction:column;
    }
    footer .f-left,
    footer .f-center,
    footer .f-right {
        width:100%;
        text-align:center;
        padding:3px 0;
    }
}


/* Page spacing to avoid overlap */
.page { 
    padding:80px 15px 70px 15px; 
    max-width:1000px; 
    margin:auto; 
}


/* Gallery */
.gallery-wrapper {
    position: relative;
}

.arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2em;
    cursor: pointer;
    user-select: none;
    padding: 10px;
    z-index: 10;
}

#leftArrow {
    left: 0;
}

#rightArrow {
    right: 0;
}

.gallery { 
    display:flex; 
    overflow-x:auto; 
    gap:10px; 
    padding-bottom:10px; 
    scroll-behavior:smooth;
}
.gallery img { 
    max-height:180px; 
    border-radius:6px; 
}
.item { 
    text-align:center; 
    min-width:33%; 
    cursor: pointer;
}
.timestamp { 
    font-size:0.8em; 
    color:#444; 
    margin-top:4px; 
}

/* 0–600px: 100% (egy kép per sor) */
@media (max-width: 600px) {
    .item {
        min-width: 100%;
    }
    .page {
        padding-bottom: 100px; /* eddigi 70px helyett */
    }
    .crt-frame {
        height: auto;         /* arányosan kicsinyít */
        padding: 12px;        /* keret szélesség arányos csökkentése */
    }

    .crt-screen {
        width: 100%;
        height: auto;         /* soha ne torzuljon */
        display: block;
    }

    .crt-led {
        bottom: 8px;          /* mobilon picit feljebb */
        right: 8px;
        transform: scale(0.8); /* kisebb LED, arányos */
    }

}

/* 600–800px: 50% (két kép per sor) */
@media (min-width: 600px) and (max-width: 800px) {
    .item {
        min-width: 50%;
    }
}

/* 800px felett: 33% (három kép per sor) */
@media (min-width: 800px) {
    .item {
        min-width: 33%;
    }
}

/* MODAL */

.modal {
    position:fixed;
    z-index:2000;
    left:0;
    top:0;
    width:100%;
    height:100%;
    background-color:rgba(0,0,0,0.8);
    display:flex;
    justify-content:center;
    align-items:center;

    opacity:0;
    pointer-events:none;
    visibility:hidden;
    transition:opacity 0.25s ease, visibility 0.25s ease;
}


.modal.show {
    opacity:1;
    pointer-events:auto;
    visibility:visible;
}

.modal-large {
    max-width: 80vw;
    width: 640px;   /* desktopon 640-ig, mobilon automatikusan kisebb */
    height: auto;
    max-height: 80vh;
    display: block;
    object-fit: contain;  /* ne torzuljon, ne vágja le */
    border-radius: 8px;
    box-shadow:0 0 20px #000;
    transition:transform 0.25s ease;
    transform:scale(0.95);
}

.modal-content {
    margin:auto;
    display:block;
    max-width:80%;
    max-height:80%;
    object-fit: contain;
    width: auto;
    height: auto;
    border-radius:8px;
    box-shadow:0 0 20px #000;
    transition:transform 0.25s ease;
    transform:scale(0.95);
}


.modal.show .modal-content {
    transform:scale(1);
}

.closeBtn {
    color:#fff;
    font-size:40px;
    font-weight:bold;
    cursor:pointer;
    z-index:3000;
}

.coverage-thumb {
    max-width:400px;
    width:100%;
    border-radius:8px;
    cursor:pointer;
    box-shadow:0 0 10px rgba(0,0,0,0.3);
}

.crt-frame {
    position: relative;
    width: 420px;
    max-width: 80vw;
    margin: 0 auto;
    padding: 18px;
    background: #888	;
    border-radius: 25px;
    box-shadow: 0 0 25px rgba(0,0,0,0.8),
                inset 0 0 40px rgba(0,0,0,0.9);
}

.crt-screen {
    width: 100%;
    border-radius: 12px;
    box-shadow:
        inset 0 0 25px rgba(0,255,0,0.2),
        0 0 15px rgba(0,255,0,0.15);
    filter: contrast(1.1) saturate(1.2) brightness(0.95);
}

.crt-led {
    position: absolute;
    bottom: 10px;
    right: 18px;
    width: 8px;
    height: 8px;
    background: #00ff6a;
    border-radius: 3px;
    box-shadow:
        0 0 6px rgba(0,255,120,0.8),
        0 0 14px rgba(0,255,120,0.5);
    animation: ledblink 2.5s infinite ease-in-out;
}

/* optional blinking effect */
@keyframes ledblink {
    0%, 100% { opacity: 1; }
    70%      { opacity: 0.4; }
}
