InGamecode FE
InGamecode FE
HTML Code
< !DOCTYPE html>
<html l a n g=” en ”>
<head>
<meta c h a r s e t=” u t f −8”>
< t i t l e>Hangman</ t i t l e>
<l i n k r e l=” s t y l e s h e e t ” h r e f=” c s s / s t y l e . c s s ”>
<l i n k h r e f=” h t t p s : / / f o n t s . g o o g l e a p i s . com/ c s s ? f a m i l y=Roboto+Mono” r e l=” s t y l e s h e e t ”>
< s t y l e>
body , html {
margin : 0 ;
padding : 0 ;
h e i g h t : 100%;
o v e r f l o w : hi d de n ;
}
. back−v i d e o {
position : fixed ;
top : 0 ;
l e f t : 0;
width : 100%;
h e i g h t : 100%;
object −f i t : cover ;
z−i n d e x : −1;
}
main {
position : relative ;
z−i n d e x : 1 ;
}
</ s t y l e>
< s c r i p t s r c=” s c r i p t . j s ” c h a r s e t=” u t f −8”></ s c r i p t>
</ head>
<body>
</ d i v>
<main>
<p i d=” h i n t ”></p>
<s e c t i o n c l a s s=” board ” i d=” board ”></ s e c t i o n>
<s e c t i o n c l a s s=” f i e l d ” i d=” g a l l o w s ”>
<d i v><img c l a s s=” gametab ” s r c=” img / s 0 . j p g ” a l t=” ”>
</ s e c t i o n>
<s e c t i o n c l a s s=” f i e l d ” i d=” a l f a b e t ”></ s e c t i o n>
</ main>
1
</ body>
</ html>
Explanation
HTML Document
• <!DOCTYPE html>: Declares the document type and version of HTML.
• <html lang="en">: Root element of the HTML document with language attribute set to English.
• <head>: Contains metadata, title, links to CSS and Google Fonts, and inline CSS styles.
• <meta charset="utf-8">: Sets the character encoding for the document.
CSS Styles
• body, html: Sets margin, padding, height, and overflow properties for the entire document.
• .back-video: Styles the background video to cover the entire viewport with object-fit set to cover.
• main: Styles the main content area with position relative and z-index to control stacking order.