* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@import url('./variables.css');

header,
footer,
h1,
h2,
.jacket-data-container p {
  font-family: "Alumni sans", Verdana, Geneva, Tahoma, sans-serif;
}

.contact-details,
.footer-links {
  font-family: "Atma", Verdana, Geneva, Tahoma, sans-serif;
}

h1 {
  position: relative;
  background-color: var(--dark-blue);
  color: var(--yellow);
  font-size: 1.5rem;
  text-decoration: none;
  letter-spacing: 1px;
  width: 100%;
  font-weight: bold;
  padding: 5px 15px;
  margin: 20px;
  width: calc(100% - 40px);
}

body {
  font-family: "Cantarell", Georgia, 'Times New Roman', Times, serif;
  background-color: var(--grey);
}

.mobile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  position: relative;
  border-bottom: solid 2px var(--dark-blue);
}

.mobile-header i {
  font-size: 1.9rem;
  color: var(--dark-blue);
}

nav,
#menu-checkbox {
  display: none;
}

#menu-checkbox:checked + nav {
  display: block;
}

header {
  position: relative;
  font-size: 1.5rem;
}

nav {
    position: absolute;
    background: var(--grey);
    border: solid 1px var(--dark-blue);
    width: 100%;
    left: 0px;
    top: 50px;
    z-index: 10;
}

nav a {
    display: block;
    color: var(--dark-blue);
    border: solid 1px var(--dark-blue);
    font-weight: 600;
    padding: 10px 20px;
    text-decoration: none;
}

nav a:hover,
nav a:checked {
    text-decoration: underline;
    background-color: var(--dark-blue);
    color: var(--yellow);
}

.logo-container {
    display: flex;
    justify-content: center;
    margin: 0;
}
    
.logo {
    max-width: 257px;
    height: auto;
    margin: 0;
    padding-top: 10px;
}

.cta-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.cta,
.jacket-add-to-cart,
.view-more-button,
.checkout-button,
.buy-now-button {
    display: flex;
    width: 100%;  
    margin: 10px 20px;
    width: calc(100% - 40px);  
    justify-content: center;
    align-items: center;
    height: auto;
    padding: 5px;
    background-color: var(--yellow);
    color: var(--dark-blue);
    text-decoration: none;
    font-size: 1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-weight: 900;
    border: 4px solid var(--dark-blue);
    border-radius: 5px;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
    cursor: pointer;
}

.cta:active {
    background-color: var(--dark-blue);
    color: var(--yellow);
    transform: scale(1.05);
    transition: all 0.1s ease;
}

.cta:hover {
  background-color: var(--dark-blue);
  color: var(--yellow);
}

#jacket-container {
    display: grid;
    grid-template-columns: 1fr;
    margin: 20px;
    max-width: 100%;
    gap: 15px;
}

.jacket-data-container {
    display: flex;
    flex-direction: column;
    border: 8px solid var(--dark-blue);
    border-radius: 5px;
    background-color: var(--white);
    align-items: center;
}

.jacket-data-container img {
    width: calc(100% - 80px);
    margin:  auto;
    height: auto
    display: block;
}

.jacket-data-container h2 {
    display: flex;
    justify-content: center;
    text-transform: uppercase;
    font-size: 1.8rem;
    font-weight: 800;
    text-align: center;
    text-decoration: underline;
    padding: 10px;
}

.jacket-data-container .jacket-price {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    padding: 10px 20px;
    font-weight: 600;
    color: var(--yellow);
    background-color: var(--dark-blue);
    margin: 10px 40px;
}

.jacket-data-container p {
    font-family: "Alumni sans", Verdana, Geneva, Tahoma, sans-serif;
    font-size: 1.1rem;
}

.logo-container-footer {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-top: 5px solid var(--dark-blue);  
    margin-top: 20px;
}

.logo-footer {
    width: 25vh;
    height: auto;
    padding-top: 20px;
}

footer a.footer-logo :hover,
footer a.footer-logo :focus {
    text-decoration: none;
    background-color: var(--yellow);
    color: none;
}

.social-icons a {
    font-size: 1.4rem;
    gap: 30px;
}

.contact-details,
.footer-links {
    font-family: "Atma", Verdana, Geneva, Tahoma, sans-serif;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dark-blue);
    text-align: center;
    align-items: center;
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    margin: 30px 0 20px 0;
}

footer a {
    text-decoration: none;
    color: var(--dark-blue);
    font-size: 0.875rem;
    line-height: 1.9;
    letter-spacing: 2px;
    font-weight: 700;
}

.social-icons {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding-top: 10px;
    padding-bottom: 10px;
}

footer a:hover,
footer a:focus {
    text-decoration: underline;
    background-color: var(--dark-blue);
    color: var(--yellow);
    border: 2px solid var(--dark-blue);
}

.copyright {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 0.9rem;
    margin-bottom: 20px;
    margin-top: 0;
}

body.loading {
  overflow: hidden;
}

#loading-spinner {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  transform: translate(-50%, -50%);
  z-index: 9999;
  backdrop-filter: blur(2px);
}

.loader {
  margin: 0 auto;
  border: 5px solid var(--dark-blue);
  border-top: 6px solid var(--yellow);
  border-bottom: 6px solid var(--yellow);
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1.2s ease-in-out infinite;
  box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.25);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg);
  }
}

@media (min-width: 450px) {
    #jacket-container {
    grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 700px) {
    #menu-checkbox,
    .hamburger-icon, 
    .mobile-header {
    display: none;
    }
       
    nav {
    display: flex;
    align-items: center;
    justify-content: space-around;
    align-items: center;
    background-color: var(--dark-blue);
    padding: 10px 0;
    margin: 0;
    top: 0;
    width: 100%;
    position: relative;
    }

    h1 {
    font-size: 2rem;
    padding: 10px 20px;
    margin: 20px 50px;
    width: calc(100% - 100px);
    }

    .logo-container {
    position: relative;
    justify-content: center;
    margin: 0;
    }
        
    .logo {
    padding-top: 20px;
    margin: 0;
    }

    nav a {
    display: inline-block;
    color: var(--white);
    padding: 0 15px;
    font-size: 1.5rem;
    text-transform: uppercase;
    }

    nav a:hover,
    nav a:focus {
    text-decoration: underline;
    }

    nav a i {
    font-size: 1.2rem;
    margin-left: 5px;
    }

    #jacket-container {
    grid-template-columns: repeat(3, 1fr); 
    margin: 20px 50px;
    width: calc(100% - 100px);
    }   
} 

@media (min-width:1120px) {
    #jacket-container {
    grid-template-columns: repeat(4, 1fr); 
    margin: 20px 100px 0 100px;
    width: calc(100% - 200px);
    }
    
    h1 {
    font-size: 2.5rem;
    margin: 20px 100px;
    width: calc(100% - 200px);
    }
}

