using System.Net.Mail;
using System.Reflection;
using static System.Net.Mime.MediaTypeNames;

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow-y: auto; /* allow vertical scroll */

    opacity: 0;
    transition: opacity 0.3s ease;
    color: black;
    background-color: whitesmoke;
    font-family: monospace;
    font-size: 14px;
}
    body.ready {
        opacity: 1;
    }



#debug {
    position: fixed;
    bottom: 10px;
    left: 10px;
    font-family: monospace;
    font-size: 14px;
    padding: 5px 8px;
    border-radius: 4px;
    z-index: 9999;
    pointer-events: none; /* don’t block clicks */
    white-space: pre-line; /* allows multiline text */
    opacity: 0;
    transition: opacity 0.3s ease;
    background: rgba(0, 0, 0, 0.6);
    color: #0f0;
}

/* --- BUTTONS --- */
#left-side-buttons {
    position: fixed;
    top: var(--globalPadding); /* top margin from window */
    bottom: var(--globalPadding); /* bottom margin from window */
    right: var(--globalPadding); /* right margin from window */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* top and bottom pinned */
    align-items: flex-end;
    height: calc(100vh - var(--globalPadding) - var(--globalPadding)); /* account for top/bottom margin */
    z-index: 100;
    box-sizing: border-box;
}

#contactIcon {
    position: fixed;
    top: var(--globalPadding); /* top margin from window */
    left: var(--globalPadding); /* bottom margin from window */
    z-index: 100;
    box-sizing: border-box;
}

#textIcon {
    position: fixed;
    top: var(--globalPadding); /* top margin from window */
    left: var(--globalPadding); /* bottom margin from window */
    z-index: 100;
    box-sizing: border-box;
}

/* Overlay container (hidden by default) */
#textOverlay {
    display: none; /* toggled via JS */
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6); /* translucent black */
    z-index: 99;
    pointer-events: all;
}

/* Text box */
#textBox {
    position: absolute;
    top: var(--globalPadding);
    bottom: var(--globalPadding);
    background: white;
    color: black;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    z-index: 200;
}



/* Overlay container (hidden by default) */
#textOverlayContact {
    display: none; /* toggled via JS */
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6); /* translucent black */
    z-index: 99;
    pointer-events: all;
}

/* Text box */
#textBoxContact {
    position: absolute;
    top: var(--globalPadding);
    bottom: var(--globalPadding);
    background: white;
    color: black;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    z-index:200;
}







#right-side-buttons {
    position: fixed;
    top: var(--globalPadding); /* top margin from window */
    bottom: var(--globalPadding); /* bottom margin from window */
    right: var(--globalPadding); /* right margin from window */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* top and bottom pinned */
    align-items: flex-end;
    height: calc(100vh - var(--globalPadding) - var(--globalPadding)); /* account for top/bottom margin */
    z-index: 50;
    box-sizing: border-box;
}

/* basic style for buttons */
.side-btn {
    width: var(--buttonSize);
    height: var(--buttonSize);
    padding: 4px;
    box-sizing: border-box;
    background: rgba(255,255,255,0.2);
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

    /* subtle hover */
    .side-btn:hover {
        transform: scale(1.1);
    }



/* --- SECTION A --- */


/* Signature */
#signature {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1;
    pointer-events: none;
}
    #signature img {
        width: 100%;
        height: auto;
        object-fit: contain;
        display: block;
    }


#video {
    position: fixed;
    justify-content: center;
    width: 100%;
    overflow: hidden;
    z-index: 4;
}

.frame {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
}

    .frame.active {
        opacity: 1;
        z-index: 4;
    }

    .frame img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        display: block;
    }

/* --- SECTION C --- */

/* The fixed slides container: covers the viewport and contains stacked slides */
#slidesFixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    overflow: hidden; /* we will translate its inner stack */
    z-index: 6;
    pointer-events: none; /* allow clicking through overlays if needed */
    background-color: whitesmoke;
}

    /* Each slide inside slidesFixed is stacked vertically */
    #slidesFixed .slide {
        width: 100%; /*height is calculated in script*/
        height: var(--slide-height); /* each slide surface equals viewport height */
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        overflow: hidden;
        z-index: 6;
    }

        #slidesFixed .slide img {
            width: 100vw;
            height: var(--slide-height);
            object-fit: contain;
            display: block;
            z-index: 6;
        }

/* When screen is tall → 4:3 mode: crop left/right for immersive view */
body.aspect-4-3 #slidesFixed .slide img {
    object-fit: cover; /* fill area, crop sides */
    object-position: center;
}


/* === Footer === */
footer {
    position: fixed;
    width: 100%;
    text-align: center;
    padding: 0;
    font-size: 0.9rem;
    background: white;
    z-index:10;
}


/* --- spacer --- */
#spacer {
    box-sizing: border-box;
}


/* --- scroll bar translucent --- */
/* Chrome / Edge / Safari scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0);
    background-color: transparent !important;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
}

    ::-webkit-scrollbar-thumb:hover {
        background: rgba(0, 0, 0, 0.5);
    }

::-webkit-scrollbar-corner {
    background: transparent;
}

/* Firefox */
html {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.3) transparent;
}