/*=================================================================================*/
/*    Video include DIV 4-5    START OF VIDEO EMBED STYLESHEET                     */
/*=================================================================================*/

/* Featured Video container 4 Div Opened */
.featured-video {
    width: 100%; 						/* video takes full width */
    margin-bottom: 0.625rem; 					/* Adds margin to the bottom of the video */
    background: #fff; 						/* Sets the background color to white */
    border-radius: 8px; 					/* Rounds the corners of the carousel */
    overflow: hidden; 						/* Hides anything outside the carousel container */
}

/* video container for position handling 5 Div Opened */
.video-container {
    position: relative; 					/* Ensures proper positioning for child elements */
    overflow: hidden; 						/* Hides any content that overflows the container */
}


/*=================================================================================*/
/*   Video include DIV 6-7   1st Aligning Video Stylesheet with with Carousel	   */
/*=================================================================================*/

/* video items container just to align with carousel layout and divs 6 Div Opened */
.video-items {
    display: flex; 				/* Flex Aligned carousel items in a row */
    width: 100%; 				/* Ensures enough space for multiple C items */
    /* Animated the carousel items continuously */
}

/* Individual Video item (embed) styles 7 Div Opened */
.video-item {
    width: 100%; 				/* YouTube embed iframe takes up 100% of the carousel's width */
    flex-shrink: 0; 				/* Prevents items from shrinking */
    position: relative; 			/* Allows positioning of child elements */
    aspect-ratio: 16/9;				/* claudes alernative to chatgpts padding below.Aspect ratio 16:9 (height / width = 9 / 16 = 0.5625) */
//    padding-top: 56.25%;	 /* Aspect ratio 16:9 (height / width = 9 / 16 = 0.5625) */
//    height: 0;			 /* Set to 0, as padding-top defines the height */
}

.video-item iframe {
    position: relative;  /* Changed from absolute when fixing video controls. not needed possibly */
    width: 100%;  /* Fill the container width */
    height: 100%; /* Fill the container height */
    display: block;  /* Ensure proper rendering of video controls */
    z-index: 9999;  /* Extremely high z-index to show video controls */
//    top: 0;   /* hidden during video fix */
//    left: 0;  /* hidden during video fix */






/*=================================================================================*/
/*          		   Video include DIV 7-8 			           */
/*=================================================================================*/


/* 7 Div Styles for carousel item images ad where the maxresdefault images of the videos are shown */
.video-item img {
    width: 100%; 						/* Ensures images fill the container */
    height: auto; 						/* Maintains aspect ratio of images */
    max-height: 500px; 						/* Limits the height of images */
    background: #000;                   /* Only row here different from Carousel at test. Sets a black background in case the video doesn't fill the space, or if it's loading */
    object-fit: cover; 						/* Ensures images cover the area without stretching */
}

/* 8 Div Opened Video content (embed. for Carousel page this is where title and description styling happens) */
.video-content {
    position: absolute; 					/* Positions content absolutely within the carousel */
    bottom: 0; 							/* Aligns content to the bottom */
    left: 0; 							/* Aligns content to the left */
    right: 0; 							/* Aligns content to the right */
    padding: 2rem; 						/* Adds padding around the content */
    background: linear-gradient(transparent, rgba(0,0,0,0.8)); 	/* Adds a gradient background */
    color: white; 						/* Sets text color to white */
}


/*=================================================================================*/
/*          In case of ad text or logo text over video embed use this	           */
/*=================================================================================*/

.video-content h2 {
    font-size: 1.8rem; 						/* Adjust size of the video title */
    margin-bottom: 0.5rem; 					/* Adds margin to the bottom of the title */
}


/*=================================================================================*/
/*      Adjust size of ev. ad text video title on embed on mobile here below       */
/*=================================================================================*/

@media screen and (max-width: 768px) {
    .video-content h2 {
        font-size: 1.5rem; 					/* Adjusts size of video title for mobile */
    }
}


/*=================================================================================*/
/* Adjust size of smaller video uploader style name on embed on mobile here below  */
/*=================================================================================*/

@media screen and (max-width: 768px) {
    .video-content .uploader {
        font-size: 0.75rem; 					/* Adjusts uploader name size for mobile */
    }
}

/*=================================================================================*/
/*  This is the width setting where video width is limited or expanded on mobile   */ 
/*=================================================================================*/

@media screen and (max-width: 768px) {
    .video-container {
    	width: 100%; 						/* D testing if video takes full width on mobile */
        margin-right: 0%; 					/* Fixes right margin issue on mobile */
    }

    .featured-video {
        width: 100%; 						/* Makes video wider on mobile */
    }
}

/*=================================================================================*/
/*                             END OF VIDEO STYLESHEET                             */
/*=================================================================================*/