:root {
    --font-body: 'Raleway', Arial, sans-serif;
    --font-heading: 'Playfair Display', serif;

    --color-bg: #fff;
    --color-card: #f7f9fb;
    --color-accent: #d6336c;
    --color-accent-light: #f8eaf2;
    --color-text: #232428;
    --color-hint: #888;
    --color-border: #e3e6ea;

    --radius: 8px;
    --radius-soft: 12px;
    --shadow-hero: 0 2px 22px 0 #af16632a;
    --shadow-card: 0rem 0.3rem .95rem #0001, 0rem 0.05rem .1rem #d6336c12;
}

html, body {
    margin:0; padding:0;
    background: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    min-height: 100dvh;
}

.navbar {
    height: 4em;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 10000;
    background-color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2em;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.navbar-logo a {
    display: inline-flex;
    text-decoration: none;
    color: var(--color-hint);
    font-weight: 700;
}

.navbar-logo img {
    height: 4em;
    margin: 0;
}

.navbar-logo a:hover {
    color: var(--color-text);
}

.navbar-menu {
    display: flex;
    list-style: none;
    gap: 2em;
    margin: 0;
    padding: 0;
}

.navbar-menu a {
    text-decoration: none;
    color: var(--color-hint);
}

.navbar-menu a:hover {
    color: var(--color-text);
}

.navbar-menu a.active {
    color: black;
}

.navbar-menu li a {
    display: block;
}

.main {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100vw;
    min-height: 100svh;
    padding-top: 4em;
    box-sizing: border-box;
}
.hero {
    width: 100%;
    aspect-ratio: 16/12;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}
.hero-img {
    width: 101%;
    height: 101%;
    box-sizing: border-box;
    object-fit: cover;          /* <-- dôležité! */
    display: block;
    filter: brightness(0.92); // voliteľné
}
.hero-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: var(--font-heading);
    font-size: clamp(2rem,6vw,2.8rem);
    color: #fff;
    background: rgba(0,0,0,0.14);
    text-shadow: 0 2px 24px #0008;
    font-weight: 700;
    user-select: none;
    pointer-events: none;
    letter-spacing: 0.045em;
    text-align: center;
}

.card {
    width: calc(100% - 30px);
    margin: 15px 0px;
    background: var(--color-card);
    border-radius: var(--radius-soft);
    box-shadow: var(--shadow-card);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    border: 1px solid var(--color-border);
    box-sizing: border-box;
}

.hint, .upload-desc, .upload-key, .gallery-hint {
    color: var(--color-hint);
    text-align: center;
    font-size: 1.03rem;
    margin: 3px 0;
}
.upload-desc, .upload-key {
    font-size: 0.93rem;
}
.center { text-align:center;}

.button-file-row {
    display: flex;
    gap: 30px;
    width: 100%;
    justify-content: center;
    margin: 12px 0;
    margin-bottom: 30px;
}
.button-file {

    background: var(--color-accent-light);
    border-radius: 50%;
    box-sizing: border-box;
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.7px dashed var(--color-accent);
    box-shadow: 0 2px 15px #d6336c13;
    cursor: pointer;
    transition: border 0.15s, background 0.17s;
    margin: 0;
}
.button-file:active, .button-file:hover {
    border-color: #9d2450;
    background: #fae6ef;
}
.material-icons {
    font-size: 2.2em;
    color: var(--color-accent);
    display: block;
    pointer-events:none;
    user-select: none;
}

.button-upload {
    width: 100%;
    margin: 14px 0 20px 0;
    padding: 14px 0;
    border-radius: var(--radius);
    border: none;
    background: var(--color-accent);
    color: #fff;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 1.08rem;
    box-shadow: 0 1px 6px 0 #d6336c26;
    cursor: pointer;
    transition: background 0.15s;
}
.button-upload:hover, .button-upload:active { background: #a62c5b; }

.status {
    color: var(--color-hint);
    min-height: 1.3em;
    text-align: center;
    font-size: 1.03rem;
    margin-top: 7px;
}

.gallery-title {
    margin: 1.2em 0 0.2em 0;
    font-family: var(--font-heading);
    font-size: 1.35em;
    color: var(--color-accent);
    text-align: center;
    font-weight: 700;
    letter-spacing: 0.05em;
}
.gallery-hint {
    font-size: 0.97em;
    margin-bottom: 7px;
}
.gallery-section{
    box-sizing: border-box;
    width: calc(100% - 30px);

}
.gallery {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr; /* na mobile 2! */
    gap: 10px;
    background: var(--color-card);
    border-radius: var(--radius-soft);
    box-sizing: border-box;
    margin: 0 auto;
    justify-content: center;
}

/* Mobil aj default: 2 stĺpce */
.gallery {
    grid-template-columns: 1fr 1fr;
}

/* Tablet na šírku a malý desktop: 3 stĺpce */
@media (min-width: 600px) {
    .gallery {
        grid-template-columns: 1fr 1fr 1fr;
    }
}
/* Väčší desktop: 4 stĺpce */
@media (min-width: 900px) {
    .gallery {
        grid-template-columns: 1fr 1fr 1fr 1fr;
    }
}
/* Veľmi široké obrazovky: 5 stĺpcov */
@media (min-width: 1200px) {
    .gallery {
        grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
    }
}

.thumb {
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--color-border);
}
.thumb img {
    width: 100%;
    height: 21vw;
    min-height: 75px;
    max-height: 130px;
    object-fit: cover;
    display: block;
    border-radius: 5px;
}

.footer {
    width: 100%;
    max-width: 480px;
    text-align: center;
    margin: 18px auto 0 auto;
    color: var(--color-hint);
    font-size: 0.98em;
    opacity: .85;
    padding-bottom: 20px;
}

.loader {
    border: 3px solid #e9b6cf;
    border-top: 3px solid #d6336c;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    animation: spin 0.8s linear infinite;
    margin: 14px auto;
    display: block;
}
@keyframes spin {
    to {transform: rotate(360deg);}
}
.selected-files {
    font-size: 1.01em;
    color: #888;
    text-align: center;
    margin: 8px 0 4px 0;
    min-height: 1.2em;
    word-break: break-all;
}

.selected-files {
    font-size: 1em;
    color: #888;
    text-align: center;
    margin: 10px 0 8px 0;
    min-height: 1.2em;
    word-break: break-all;
}
.thumb-previews {
    display: flex;
    gap: 7px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 0 0 7px 0;
}
.thumb-preview img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 6px;
    border: 1.5px solid #f2b5d3;
    box-shadow: 0 2px 4px #0001;
}

/* Overlay loader */
#overlay-loader {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: none;
    align-items: center;
    justify-content: center;
}
.overlay-backdrop {
    position: absolute;
    inset:0;
    background: rgba(255,255,255,0.82);
    z-index: 1;
}
.overlay-spinner {
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.loader {
    border: 4px solid #f2b5d3;
    border-top: 4px solid #d6336c;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    animation: spin 0.8s linear infinite;
    margin-bottom: 16px;
    background: transparent;
}
.overlay-text {
    color: #a62c5b;
    font-size: 1.15em;
    font-family: var(--font-body);
    font-weight: bold;
    letter-spacing: 0.04em;
    text-align: center;
}
@keyframes spin {
    to {transform:rotate(360deg);}
}

/* Button upload fix: vždy rovnaká šírka */
.button-upload {
    width: 100%;
    display: block;
    margin: 14px 0 2px 0;
}

.button-upload:disabled {
    background: #e8e8ed !important;
    color: #b9b9bb !important;
    cursor: not-allowed;
    box-shadow: none;
    border: none;
    opacity: 0.76;
    transition: none;
    pointer-events: none;
}
.button-upload:disabled:hover, .button-upload:disabled:active {
    background: #e8e8ed !important;
    color: #b9b9bb !important;
}


/* === LIGHTBOX MODAL GALÉRIE === */
.lightbox-modal {
    position: fixed;
    z-index: 1200;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: background 0.13s;
}
.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(23,23,23,0.81);
    z-index: 1;
}
.lightbox-modal img {
    position: relative;
    z-index: 10;
    max-width: 94vw;
    max-height: 74vh;
    border-radius: 12px;
    box-shadow: 0 4px 32px #0008;
    background: #fff;
    margin: 0 0 16px 0;
    display: block;
    object-fit: contain;
    border: 1px solid #e3e6ea;
}
.lightbox-close,
.lightbox-prev,
.lightbox-next,
.lightbox-download {
    position: absolute;
    z-index: 12;
    background: #fff;
    color: #c71b67;
    border: none;
    border-radius: 50%;
    width: 42px;
    height: 42px;
    box-shadow: 0 2px 14px #0002;
    font-size: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background .15s, color .15s;
    opacity: 0.84;
    border: 1px solid #e3e6ea;
}

.lightbox-close { top: 26px; right: 30px; font-size: 2.2em; color: #232428; border-radius: 50%;}
.lightbox-prev  { left: 18px; top: calc(50% - 22px);}
.lightbox-next  { right: 18px; top: calc(50% - 22px);}
.lightbox-download { bottom: 32px; right: 28px; background: #fff; color: #d6336c;
    font-size:1.5em; border-radius:10px; width:auto; height:auto; padding:10px 11px;}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover,
.lightbox-download:hover {
    background: #ffe7f4;
    color: #ad2672;
    opacity: 1;
    box-shadow: 0 4px 32px #c71b679e, 0 2px 8px #0003;
}

/* Lightbox - efekt pri zobrazení */
.lightbox-modal:not(.visible) { opacity: 0; pointer-events: none; transition: opacity 0.22s; }
.lightbox-modal.visible { opacity: 1; pointer-events: all; }

@media (max-width: 700px) {
    .lightbox-modal img { max-width: 98vw; max-height: 55vh;}
    .lightbox-close, .lightbox-prev, .lightbox-next { width: 36px; height: 36px; font-size: 1.3em;}
    .lightbox-download { bottom: 14px; right: 10px; padding:8px 8px; font-size:1.2em;}
}






















.admin-thumb {
    position: relative; /* pre správne umiestnenie koša */
}
.delete-photo {
    position: absolute;
    top: 8px; right: 8px;
    background: rgba(255,255,255,0.96);
    color: #c71b67;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 1px 4px #0001;
    cursor: pointer;
    z-index: 2;
    transition: background 0.16s, color 0.18s;
    font-size: 1.5em;
    padding: 0;
}
.delete-photo:hover {
    background: #ffe3f1;
    color: #87225b;
}

/* KRÁSNY ČERVENÝ DELETE ALL */
.delete-all {
    display: block;
    margin: 18px auto 8px auto;
    background: #ee2259;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px 28px;
    font-size: 1.09rem;
    font-family: var(--font-body);
    font-weight: 700;
    letter-spacing: 0.01em;
    cursor: pointer;
    box-shadow: 0 1px 7px #e2162978, 0 1.5px 10px #0001;
    transition: background 0.18s;
}

.delete-all:hover, .delete-all:active { background: #9a0f30; }