@import url("https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&family=Roboto:ital,wght@0,100..900;1,100..900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Albert+Sans:ital,wght@0,100..900;1,100..900&display=swap");

/*Global styles*/
* {
  box-sizing: border-box;
}

:root {
  --light-gray-background: #f5f5f5;
  --primary-color: #0a3641;
  --secondary-color: #bfe1ea;
}

/*Changed body text font from microsoft sans serif to Arial, Helvetica, sans-serif*/

body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  font-family: Arial, Helvetica, sans-serif;
}

.with-header-liner .header {
  border-bottom: 2px solid var(--secondary-color);
}

html,
body {
  height: 100%;
}

main {
  flex-grow: 1;
}

.product-card :hover {
  opacity: 90%;
}

.check-out a:hover,
.pay a:hover,
.add-to-cart a:hover {
  opacity: 70%;
}

/*------------------------------------Home page------------------------------------*/

/*Header Navigation*/
.header {
  margin: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
}

.logo {
  height: auto;
  width: 100%;
  max-width: 300px;
}

.navigation {
  flex: 1;
  display: flex;
  justify-content: center;
}

.nav-list {
  list-style: none;
  font-size: 1.2rem;
  display: flex;
  gap: 7rem;
  margin: 0;
  padding: 0;
}
.shop-men {
  text-decoration: none;
  color: black;
}
.nav-list :hover {
  text-decoration: underline;
}

.close-button {
  display: none;
}

.nav-icon {
  display: flex;
  gap: 2rem;
  font-size: 1.5rem;
  padding-right: 2rem;
}

.nav-icon {
  justify-content: flex-end;
}

#hamburger-menu {
  display: none;
}

/*Hero image home page*/

.hero {
  height: auto;
  width: 100%;
  position: relative;
}

.hero > video {
  object-fit: cover;
  height: 100%;
  width: 100%;
}

#background-video > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  text-align: center;
  padding: 1rem;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6);
}

.hero-content h1 {
  font-size: 4rem;
  background-color: rgba(0, 0, 0, 0.4);
  border-radius: 10px;
}
.hero-content h2 {
  font-size: 2.8rem;
  background-color: rgba(0, 0, 0, 0.4);
  border-radius: 10px;
}

.shop {
  display: flex;
  margin-top: 15rem;
}

.shop-button {
  background-color: var(--secondary-color);
  padding: 1rem 3rem;
  text-decoration: none;
  color: black;
  border-radius: 10px;
  font-size: 1.5rem;
  flex: 1;
  text-align: center;
  margin: 2rem;
}

.shop-button:hover {
  opacity: 50%;
}

/*Popular products*/

.h1-popular-products {
  text-align: center;
  margin-top: 6rem;
  margin-bottom: 6rem;
  font-size: 2.5rem;
}
.popular-products {
  display: flex;
  text-align: center;
  margin-bottom: 6rem;
  justify-content: center;
}
.products {
  display: grid;
  grid-template-columns: 33% 33% 33%;
  text-align: center;
  margin: 0 4rem 4rem 4rem;
}

.product-card {
  background-color: var(--light-gray-background);
  margin: 2rem;
  padding-top: 2rem;
}

.product-card h3 {
  font-size: 1.8rem;
  font-weight: bold;
}
.product-card p {
  font-size: 1.8rem;
}
.popular-products img,
.products img {
  height: auto;
  max-width: 60%;
}

/*Breadcrumbs navigation*/
.breadcrumbs {
  list-style: none;
  margin: 1rem;
  padding: 0;
  display: flex;
  gap: 0.5rem;
  font-size: 1.2rem;
}

.breadcrumbs li {
  display: flex;
  align-items: center;
}

.breadcrumbs li:not(:last-child)::after {
  content: ">";
  margin: 0 0.5rem;
  color: #aaa;
}

.breadcrumbs li[aria-current="page"] {
  font-weight: bold;
}
.breadcrumbs a {
  text-decoration: none;
  color: black;
  opacity: 70%;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

/*------------------------------------Product page------------------------------------*/

/*Banner on the product page*/
.banner {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.banner-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.banner-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  text-align: center;
  padding: 1rem;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6);
  background-color: rgba(0, 0, 0, 0.4);
  border-radius: 10px;
}

h1 {
  font-family: DM sans;
  font-weight: 700;
}
h2,
h3 {
  font-family: Albert sans;
  font-weight: 600;
}

/*------------------------------------Darwin Jacket product page------------------------------------*/

.product-specific {
  display: grid;
  grid-gap: 2rem;
  grid-template-columns: 1fr 1fr;
  max-width: 90%;
  align-self: center;
}

.product-description h1 {
  font-size: 3rem;
}
.product-description h2 {
  font-size: 2.2rem;
}

.product-description p {
  font-size: 1.4rem;
}

.darwin-product img {
  height: auto;
  max-width: 70%;
  background-color: var(--light-gray-background);
  margin-left: 6rem;
  margin-top: 3rem;
  margin-bottom: 4rem;
}

.product-content {
  margin-top: 2rem;
  display: grid;
  grid-gap: 2rem;
  grid-template-rows: 15.5rem 8rem 3rem;
  max-width: 60%;
}

.sizes {
  gap: 2rem;
}

.sizes button {
  padding: 1rem;
  margin: 0.2rem;
  flex: 1;
  text-transform: uppercase;
  width: 14%;
  transition-duration: 0.4s;
  border: none;
}

.sizes button:hover {
  background-color: var(--secondary-color);
}

.add-to-cart {
  display: flex;
}

.add-to-cart a {
  color: white;
  background-color: black;
  text-decoration: none;
  padding: 1rem 4rem;
  text-transform: uppercase;
  flex: 1;
  text-align: center;
}

/*--------------------------------------Cart page--------------------------------------*/

.cart-badge {
  position: absolute;
  background-color: var(--secondary-color);
  color: black;
  font-weight: 600;
  font-size: 1rem;
  text-align: center;
  border-radius: 50%;
  width: 1.2rem;
  height: 1.2rem;
  right: 3.4rem;
}

.cart-page h1 {
  margin-bottom: 4rem;
  text-align: center;
}

.cart-page {
  display: flex;
  flex-direction: column;
  max-width: 50%;
  margin: 0 auto;
}

.cart-items {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-left: 2rem;
}

.darwin-product-cart img {
  width: 90%;
  height: auto;
  background-color: var(--light-gray-background);
}

.cart-total {
  display: flex;
  flex-direction: column;
  margin: 5rem 2.1rem 2.2rem 2.1rem;
  border-top: solid var(--secondary-color);
}

.cart-total span {
  text-transform: uppercase;
}

.check-out {
  display: flex;
  max-width: 100%;
  margin-top: 3rem;
  margin-bottom: 3rem;
}

.check-out a {
  color: white;
  background-color: black;
  text-decoration: none;
  padding: 1rem 4rem;
  text-transform: uppercase;
  flex: 1;
  text-align: center;
}

/*------------------------------------Payment page------------------------------------*/

.payment-page-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: 80%;
  justify-self: center;
  height: auto;
  margin: 3rem 6rem;
  gap: 4rem;
}

/*Form*/

input,
select,
textarea {
  border: 1px solid rgba(0, 0, 0, 0.2);
  margin: 0.6rem;
  padding-right: 2rem;
}

.payment-form {
  width: 100%;
  box-sizing: border-box;
}

fieldset {
  margin-top: 1rem;
}

.delivery input[type="text"] {
  width: 90%;
}

.payment-form input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"] {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid #ddd;
  border-radius: 0.3rem;
  font-size: 0.8rem;
  margin-bottom: 1.3rem;
}

.payment-form input,
.payment-form select,
.payment-form textarea {
  box-sizing: border-box;
  max-width: 100%;
}

.payment-form input {
  margin-left: 0;
}

.form-group {
  margin-bottom: 0;
}

.form-row,
.form-row3 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-row2 {
  display: grid;
  grid-template-columns: 0.7fr 1fr;
  gap: 1rem;
}

.contact-information {
  display: grid;
}

fieldset {
  display: grid;
  border: none;
}

legend {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.shipping {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.shipping-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.shipping-option label {
  display: flex;
  justify-content: space-between;
  flex: 1;
  align-items: center;
}

.extra {
  white-space: nowrap;
}

.terms {
  text-decoration: underline;
}

.pay {
  display: flex;
  max-width: 100%;
  margin-top: 1rem;
}

.pay a {
  background-color: black;
  color: white;
  text-decoration: none;
  padding: 1rem 4rem;
  margin: 1rem 1rem;
  text-transform: uppercase;
  justify-content: center;
  flex: 1;
}

/*Cart summary*/

.cart-summary {
  background-color: var(--light-gray-background);
}

.cart-summary h1 {
  text-align: center;
}

.darwin-product2 img {
  width: 90%;
  height: auto;
  background-color: white;
}

.darwin-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-left: 2rem;
}

.p1-product-content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.h3-darwin h3 {
  font-weight: 400;
}

.h3-darwin p {
  font-weight: bold;
}

.size-summary span {
  font-weight: bold;
}

.discount-code {
  display: flex;
  max-width: 100%;
  box-sizing: border-box;
  align-items: center;
  margin-left: 1rem;
  margin-top: 3rem;
  gap: 3rem;
}

.discount-code input {
  width: 100%;
  padding: 0.8rem 1rem;
  border-radius: 0.3rem;
  border: 1px solid #ddd;
  font-size: 1rem;
  margin-left: 1rem;
}

.discount-code button {
  background-color: black;
  color: white;
  padding: 0.6rem 3rem;
  font-size: 1rem;
  margin-right: 1rem;
}

.total {
  display: flex;
  flex-direction: column;
  margin: 1rem 2.2rem;
}

.total p,
.cart-total p {
  display: flex;
  justify-content: space-between;
  flex: 1;
  align-items: center;
}

.total span {
  text-transform: uppercase;
}

.total2 {
  font-weight: bold;
}

/*------------------------------------Loading page-----------------------------------*/

.loading-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-top: 7%;
  margin-bottom: 7%;
}

.processing {
  animation: text-loading 1.3s ease-in-out infinite alternate;
}

.loading-spinner {
  aspect-ratio: 1;
  width: 10rem;
  height: 10rem;
  overflow: hidden;
  position: relative;
  margin-top: 3rem;
}

.spinner {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 8px solid transparent;
  animation: rotate 1.3s ease-in-out infinite;
}

.spinner-sector-1,
.spinner-sector-2 {
  border-top-color: var(--primary-color);
  border-bottom-color: var(--primary-color);
}

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

@keyframes text-loading {
  0% {
    color: rgba(0, 0, 0, 1);
  }
  50% {
    color: rgba(0, 0, 0, 0.5);
  }
  100% {
    color: rgba(0, 0, 0, 0.1);
  }
}

/*------------------------------------Payment successful-----------------------------------*/

.payment-successful {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 7%;
  margin-bottom: 7%;
}

.payment-successful p {
  font-size: 1.2rem;
  text-align: center;
}
.payment-successful i {
  font-size: 4rem;
  color: var(--primary-color);
}

/*Footer*/

footer {
  background-color: var(--primary-color);
  color: white;
  padding: 1rem 2rem;
}
.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.socials i {
  font-size: 23px;
  margin: 0.9rem;
}
.socials :hover {
  opacity: 50%;
}
.footer-nav {
  display: flex;
  list-style: none;
  font-size: 1.1rem;
  gap: 8rem;
}
.footer-nav :hover {
  text-decoration: underline;
}
.footer-form input {
  width: 100%;
  padding: 0.5rem 1.5rem;
  font-size: 0.9rem;
}

.footer-form button {
  background-color: var(--secondary-color);
  padding: 0.2rem 1.3rem;
  text-decoration: none;
  color: black;
  border-radius: 10px;
  font-size: 1rem;
  white-space: nowrap;
}

.footer-form {
  display: flex;
  width: 100%;
  box-sizing: border-box;
  align-items: center;
}

/*------------------------------------Media queries-----------------------------*/

/*-----Fluid breakpoints-----*/

@media (max-width: 1138px) {
  .footer-nav {
    gap: 5rem;
    font-size: 1rem;
  }
}

@media (max-width: 1385px) {
  .socials {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, auto);
  }
  .footer-nav {
    gap: 5rem;
  }
}

@media (max-width: 1385px) {
  .nav-list {
    gap: 4rem;
  }
  .shop {
    margin-top: 10rem;
  }
}

@media (max-width: 1434px) {
  .sizes button {
    width: 12%;
    padding: 0.8rem;
  }
  .product-description h1 {
    font-size: 2rem;
  }

  .product-description h2 {
    font-size: 1.5rem;
  }

  .product-description p {
    font-size: 1.2rem;
  }

  .product-content {
    grid-gap: 1rem;
  }
}

@media (max-width: 1650px) {
  .hero-content h1 {
    font-size: 3rem;
  }
  .hero-content h2 {
    font-size: 2.1rem;
  }

  .shop-button {
    font-size: 1rem;
    padding: 0.7rem 1rem;
  }
}

@media (min-width: 554px) and (max-width: 768px) {
  .add-to-cart {
    margin-bottom: 1rem;
  }
  .product-specific {
    width: 70%;
  }
}

@media (min-width: 769px) {
  .hero-image {
    display: none;
  }
}

/*-----Small desktop-----*/

@media (min-width: 769px) and (max-width: 1024px) {
  /*Header*/
  .breadcrumbs {
    font-size: 1rem;
  }

  .logo {
    max-width: 10rem;
  }

  .nav-list {
    font-size: 1rem;
    gap: 2.5rem;
  }
  .nav-icon {
    font-size: 1rem;
    gap: 1.5rem;
    padding-right: 0;
  }
  /*Main page*/
  .hero-content {
    top: 50%;
    width: 70%;
  }

  .shop {
    margin-top: 3rem;
  }

  .h1-popular-products {
    font-size: 2rem;
    margin-top: 3rem;
    margin-bottom: 3rem;
  }

  /*Product page*/
  .banner-content {
    width: 100%;
  }

  .banner-content h2 {
    font-size: 1.3rem;
  }

  .product-card {
    margin: 0.8rem;
  }

  .product-card h3,
  .product-card p {
    font-size: 1.4rem;
  }

  /*Darwin jacket*/
  .product-specific {
    grid-gap: 0.5rem;
  }
  .product-content {
    margin-top: 0;
    margin-bottom: 1rem;
    max-width: 80%;
  }

  /*Cart page*/
  .cart-page {
    max-width: 60%;
  }
  .cart-badge {
    position: absolute;
    font-size: 1rem;
    width: 1.2rem;
    height: 1.2rem;
    right: 1.2rem;
    top: 4.1rem;
  }

  /*Payment page*/
  .payment-page-container {
    max-width: 100%;
    margin: 1rem 1rem;
    gap: 1rem;
  }
  .pay {
    margin: 0;
    margin-top: 1rem;
  }

  /*Footer*/
  .footer-content {
    flex-direction: column-reverse;
  }
  .socials {
    display: flex;
  }

  .footer-nav {
    font-size: 1rem;
    gap: 0.8rem;
    padding: 0;
  }

  .form p {
    text-align: center;
  }
}

/*-----Mobile phone and tablets-----*/

@media (max-width: 768px) {
  .header {
    display: flex;
  }
  .header > a {
    order: 1;
    flex: 1;
  }

  .nav-icon {
    justify-content: flex-end;
    order: 2;
  }

  .hamburger-icon {
    order: 3;
  }
  .navigation {
    display: none;
    flex-direction: column;
    align-items: center;
    height: 30%;
    z-index: 999;
  }
  #hamburger-menu:checked ~ .navigation {
    display: flex;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #bfe1ea;
    align-items: center;
    justify-content: center;
  }
  .nav-list {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
  }

  .close-button {
    display: block;
    font-size: 2rem;
    position: absolute;
    top: 1rem;
    right: 2rem;
  }
  /*Product-page*/

  .banner-content h2 {
    display: none;
  }

  .banner-content h1 {
    font-size: 1rem;
  }

  .products {
    grid-template-columns: 50% 50%;
    margin: 0.5rem;
  }

  .product-card {
    margin: 0.5rem;
  }

  .product-card h3 {
    font-size: 1.3rem;
  }

  .product-card p {
    font-size: 1.1rem;
  }

  /*Darwin product*/

  .product-specific {
    grid-template-columns: auto;
    align-content: center;
    grid-gap: 0;
  }

  .darwin-product img {
    max-width: 100%;
    margin: 0;
  }

  .product-content {
    max-width: 100%;
    margin-top: 0;
    grid-gap: 0;
    grid-template-rows: 1fr 0.6fr 0.3fr;
  }

  .product-description h1 {
    font-size: 2rem;
    margin-bottom: 0.3rem;
  }

  .product-description h2 {
    font-size: 1.5rem;
    margin-top: 0;
  }

  .product-description p {
    font-size: 1.2rem;
    margin-bottom: 0;
  }

  .sizes {
    width: 100%;
    height: 90px;
    margin-bottom: 1rem;
  }

  .sizes h2 {
    margin-top: 1rem;
    margin-bottom: 1rem;
  }

  .sizes button {
    padding: 0.4rem;
    font-size: 0.8rem;
    margin: 0;
  }

  /*Payment page*/

  .payment-page-container {
    display: flex;
    flex-direction: column-reverse;
    max-width: 100%;
    margin: 1rem 1rem;
  }

  .payment-form,
  .cart-summary {
    width: 100%;
  }

  .yes-check,
  .terms-and-conditions {
    display: flex;
    font-size: 0.9rem;
  }

  .yes-check input,
  .terms-and-conditions input {
    margin-top: 0;
  }

  .payment-form input::placeholder {
    font-size: 0.8rem;
  }

  .payment-form input {
    margin-left: 0;
  }

  .pay {
    margin: 0;
    margin-top: 2rem;
  }

  .cart-summary {
    display: flex;
    flex-direction: column;
    width: 100%;
  }

  .discount-code {
    display: flex;
    flex-direction: column;
    margin-left: 0;
    margin-top: 0;
    gap: 1rem;
  }

  .discount-code input {
    width: 100%;
    margin-left: 0;
    box-sizing: border-box;
  }

  .darwin-summary {
    grid-template-columns: 1fr;
    margin-left: 1rem;
  }

  /*Footer*/
  .footer-content {
    flex-direction: column-reverse;
  }
  .socials {
    display: flex;
  }

  .footer-nav {
    font-size: 1rem;
    gap: 0.8rem;
    padding: 0;
  }

  .form p {
    text-align: center;
  }
}

/*-----Tablets-----*/

@media (min-width: 481px) and (max-width: 768px) {
  /*Home-page*/

  .logo {
    max-width: 15rem;
  }

  .nav-icon,
  .hamburger-icon {
    font-size: 1.5rem;
  }

  .nav-icon {
    gap: 1rem;
    padding-right: 0.7rem;
  }

  .breadcrumbs {
    font-size: 0.8rem;
  }

  video {
    display: none;
  }

  .hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
  }

  .hero-content h1 {
    font-size: 2.3rem;
  }
  .hero-content h2 {
    font-size: 1.5rem;
  }

  .hero-content {
    top: 45%;
    width: 80%;
  }

  .shop {
    margin-top: 3rem;
  }

  .shop-button {
    font-size: 1rem;
    padding: 0.7rem 1rem;
    margin: 0.5rem;
  }

  .h1-popular-products {
    font-size: 2.3rem;
    margin-top: 3rem;
    margin-bottom: 3rem;
  }

  .popular-products {
    flex-direction: column;
  }

  /*Cart-page*/

  .cart-page {
    margin: 0;
    max-width: 100%;
  }
}

@media (min-width: 769px) {
  .hamburger-icon {
    display: none;
  }
}

/*-----Mobile phones-----*/

@media (max-width: 480px) {
  /*Home page*/

  .logo {
    max-width: 8rem;
  }

  .nav-icon,
  .hamburger-icon {
    font-size: 1.2rem;
  }

  .nav-icon {
    gap: 0.7rem;
    padding-right: 0.7rem;
  }

  .breadcrumbs {
    font-size: 0.8rem;
  }

  video {
    display: none;
  }

  .hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
  }

  .hero-content h1 {
    font-size: 1.5rem;
  }
  .hero-content h2 {
    font-size: 1rem;
  }

  .hero-content {
    top: 50%;
    width: 90%;
  }

  .shop {
    margin-top: 0.5rem;
    flex-direction: column;
    align-items: center;
  }

  .shop-button {
    width: 60%;
    font-size: 1rem;
    padding: 0.7rem 1rem;
    margin: 0.3rem;
  }

  .h1-popular-products {
    font-size: 2.3rem;
    margin-top: 3rem;
    margin-bottom: 3rem;
  }

  .popular-products {
    flex-direction: column;
  }

  /*Product-page*/

  .banner-content {
    width: 45%;
  }

  .banner-content h1 {
    font-size: 0.7rem;
  }

  /*Cart page*/

  .cart-page {
    max-width: 100%;
  }

  .cart-badge {
    width: 1rem;
    height: 1rem;
    font-size: 0.8rem;
  }

  .cart-items {
    margin-top: 1rem;
  }

  .cart-total {
    margin-top: 3rem;
  }

  .h3-darwin p {
    margin-bottom: 0;
  }

  .h3-darwin h3 {
    margin-top: 0.5rem;
  }

  /*Payment successful*/

  .payment-successful {
    max-width: 100%;
    text-align: center;
    padding-left: 2rem;
    padding-right: 2rem;
  }

  .footer-form {
    flex-direction: column;
  }
}
