/* rem and em do NOT depend on html font-size in media queries 
 * Instead, we assume that 1rem = 1em = 16px */


/*-------------- BELOW 768px --------------*/

@media (max-width: 48em){
    .main-nav-list {
        gap: 1.6rem;
    }
    
}

/*-------------- BELOW 720px --------------*/

@media (max-width: 45em){
    .main-nav-link:link,
.main-nav-link:visited {
        font-size: 1.2rem;
    }
}

/*-------------- BELOW 640px --------------*/

/* MOBILE NAVIGATION COMES IN HERE */
@media (max-width: 40em){
    .btn-mobile-nav {
        display: block;
        z-index: 999;

    }
    
    .main-nav {
        background-color: rgba(255, 255, 153, 0.97);
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        transform: translateX(100%);
        
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.5s ease-out;
        z-index: 998;
        
        /* Hide navigation */
        /* Allows NO transitions at all*/ 
        /*display: none;*/
        
        /* 1) Hide Visually */
        opacity: 0;
        
        /* 2) Make it unaccesible to mouse and keyboard */
        pointer-events: none;
        
        /* 3) Hide it from screen readers */
        visibility: hidden;
    }
    
    .nav-open .main-nav {
        opacity : 1;
        pointer-events: auto;
        visibility: visible;
        transform: translateX(0);
    }
    
    .nav-open .icon-mobile-nav[name="close-outline"] {
        display: block;
    }
    
    .nav-open .icon-mobile-nav[name="menu-outline"] {
        display: none;
    }
    
    .main-nav-list {
        flex-direction: column;
        gap: 4-8rem;
    }
    
    .main-nav-link:link,
    .main-nav-link:visited {
        font-size: 3rem;
    }
    
    /* NOT MOBILE NAVIGATION RELATED */
    .grid--2-cols {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .grid {
        gap: 1rem;
    }
    
    .centering-box, .end-box, .start-box {
        text-align: center;
    }
 
}

/*-------------- BELOW 544px --------------*/
@media (max-width: 34em){
    h1 {
        font-size: 80px;
    }
    
    .hero h2 {
        font-size: 40px;
    }
}

/*-------------- BELOW 448px --------------*/
@media (max-width: 28em)
{
    h1 {
        font-size: 60px;
    }
    .hero h2 {
        font-size: 30px;
    }
    
    .logo {
        height: 4rem;
    }
}