@media screen and (orientation: landscape){
html,body {
display: grid;
grid-template-areas:
    "header header header"
    "section main main"
    "footer footer footer";
grid-template-columns: 1fr 9fr 1fr;
grid-template-rows: 2fr 10fr 3fr;
height: 100vh;
width: 100vw;
margin: 0;
}
header {
display: flex;
flex-flow: column nowrap;
grid-area: header;
justify-content: space-around;
align-items: center;
}
header .headerdiv {
display: flex;
flex-flow: row nowrap;
justify-content: space-evenly;
align-items: center;
width: 90%;
min-height: 40px;
margin: 3px 15px;
border-radius: 5px;
}
header .headerdiv .dropdown {
display: flex;
align-items: center;
justify-content: space-evenly;
height: 80%;
min-width: 40px; 
border-radius: 5px;
}
section {
display: grid;
grid-area: section;
}
main  {
display: flex;
flex-flow: row nowrap;
justify-content: center;
align-items: center;
grid-area: main;
}
.maindiv {
width: 80%;
display: flex;
flex-flow: row wrap;
justify-content: center;
align-items: flex-start;
margin: auto;
}
footer {
display: grid;
grid-area: footer;
margin: 0px;
}
main #imageframe{
display: flex;
object-fit: cover;
flex-flow: column nowrap;
justify-content: flex-start;
align-items: center;
margin: auto;
height: 300px;
}
main #imageframe > #image{
min-height: 1px;
max-height: 210px;
width: 98%;
object-fit: fill;
margin: 0px;
filter: grayscale(50%); /* Apply grayscale effect */
transition: transform 3s ease-in-out;
}
main #imageframe > #imagedetail{
display:flex;
flex-flow: row nowrap;
justify-content: space-evenly;

align-items: space-evenly;
object-fit: contain;
height: 20%;
width: 98%;
filter: grayscale(50%);  
}
main #imageframe #image:hover {
      z-index: 1;
      transform: scale(1.5); /* Slight zoom on hover */
      filter: grayscale(0%); /* Remove grayscale on hover */
} 
}    
@media screen and (orientation: portrait){
html,body {
display: grid;
grid-template-areas:
    "header header header"
    "main main main"
    "footer footer footer";
grid-template-columns: 1fr 9fr 1fr;
grid-template-rows: 2fr 10fr 3fr;
height: 100vh;
width: 100vw;
margin: 0;
}
header {
display: flex;
flex-flow: column nowrap;
grid-area: header;
justify-content: space-around;
align-items: center;
}
header .headerdiv {
display: flex;
flex-flow: row nowrap;
justify-content: space-evenly;
align-items: center;
width: 90%;
min-height: 40px;
margin: 3px 15px;
border-radius: 5px;
}
header .headerdiv .dropdown {
display: flex;
align-items: center;
justify-content: space-evenly;
height: 80%;
min-width: 40px; 
border-radius: 5px;
}
section {
display: grid;
grid-area: section;
}
main  {
display: flex;
flex-flow: row nowrap;
justify-content: center;
align-items: center;
grid-area: main;
}
.maindiv {
width: 80%;
display: flex;
flex-flow: row wrap;
justify-content: center;
align-items: flex-start;
margin: auto;
}
footer {
display: grid;
grid-area: footer;
margin: 0px;
}
main #imageframe{
display: flex;
object-fit: cover;
flex-flow: column nowrap;
justify-content: flex-start;
align-items: center;
margin: auto;
height: 250px;
}
main #imageframe > #image{
min-height: 185px;
max-height: 210px;
width: 98%;
object-fit: fill;
margin: 0px;
filter: grayscale(50%); /* Apply grayscale effect */
transition: transform 3s ease-in-out;
}
main #imageframe > #imagedetail{
display:flex;
flex-flow: row nowrap;
justify-content: space-evenly;
align-items: space-evenly;
object-fit: contain;
height: 20%;
width: 98%;
filter: grayscale(50%);  
}
main #imageframe #image:hover {
      z-index: 1;
      transform: scale(1.5); /* Slight zoom on hover */
      filter: grayscale(0%); /* Remove grayscale on hover */
}   
}
