/* General Styles */
body {
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    font-family: monospace;
}

/* Placemat Container */
.placemat-container {
    perspective: 500px; /* Enables 3D effect */
    position: absolute;
    z-index: 10;
    transform: rotate(-2deg);
    transition: 0.4s;
}

.placemat-container:hover {
	box-shadow: 0 4px 30px rgba(0, 0, 0, 0.9);
	transition: 0.4s;

}

/* Placemat Base Styles */
#placemat {
    background-color: white;
    width: 324px;
    height: 270px;
    position: relative;
    border-radius: 7px;
    transform-style: preserve-3d; /* Enables 3D children */
    transition: transform 0.8s; /* Smooth flip transition */
    cursor: pointer;
    z-index: 1;
    box-shadow: 0 4px 30px rgba(255, 255, 255, 0.9);
    color: #E24647;
    text-align: center;
}

#placemat::before {
    content: '';
    position: absolute;
    top: 7px;
    left: 7px;
    right: 7px;
    bottom: 7px;
    border: 1px dashed #E24647;
    border-radius: 7px;
}

/* Placemat Faces */
#placemat-front,
#placemat-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden; /* Hides back when facing front */
    border-radius: 7px;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Vertically centers content */
    align-items: center; /* Horizontally centers content */
    text-align: center; /* Ensures text is centered */
}

#placemat-back {
    transform: rotateY(-180deg); /* Prepares back face for flipping */
}

#placemat.flipped {
    transform: rotateY(-180deg); /* Flips the placemat */
}

/* Text Styling Inside Placemat */
#placemat h1 {
    margin: 20px 0 10px;
    text-transform: uppercase;
    font-weight: bold;
}

#placemat p {
    line-height: 1.5;
    font-style: italic;
}

#placemat-back h2,
#placemat-back a {
    color: black;
    width: 80%;
    font-family: "IM Fell French Canon", serif;;
}

#placemat-back h2 {
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.5;
}

#placemat-back a {
    padding-bottom: 10px;
}

/* Additional Styles */
#hex {
    font-size: 24px;
}

.border-text,
#date-time {
    color: white;
    position: absolute;
    z-index: 10;
    text-transform: uppercase;
}

p.border-text {
        text-shadow: 0px 0px 10px rgba(0,0,0,1);
}

#date-time {
    top: 12px;
}

#bottom-border-text {
    bottom: 12px;
}

.video-container {
	position: relative;
	height: 100%;
	width: 100%;
	overflow: hidden;
	z-index: 0;
}

.studio-cam {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transform: translate(-50%, -50%);
	z-index: -1;
}

/* Base styles to hide both videos by default */
.studio-cam,
.table-cam {
    display: none;
}

/* Show studio-cam on larger screens */
@media (min-width: 501px) {
    .studio-cam {
        display: block;
    }
}

/* Show table-cam on smaller screens and make it a full-screen background */
@media (max-width: 500px) {
    .table-cam {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        z-index: -1;
    }
}


/* Updated CSS for right-border-text */
#right-border-text {
    position: fixed;
    top: 50%; /* Center vertically in the viewport */
    right: 12px; /* 12px from the right edge */
    transform: translate(50%, -50%) rotate(90deg); /* Adjust centering and rotation */
    white-space: nowrap;
    line-height: 1;
    margin: 0;
}

/* Updated CSS for left-border-text */
#left-border-text {
    position: fixed;
    top: 50%; /* Center vertically in the viewport */
    left: 12px; /* 12px from the left edge */
    transform: translate(-50%, -50%) rotate(-90deg); /* Adjust centering and rotation */
    white-space: nowrap;
    line-height: 1;
    margin: 0;
}

/* Hide left-border-text and right-border-text on screens smaller than 500px */
@media (max-width: 500px) {
    #left-border-text,
    #right-border-text {
        display: none;
    }
}