
/* --------------------- */
/*   Custom properties   */
/* --------------------- */

:root {
    /* colors */
    --clr-dark: hsl(230, 35%, 7%);
    --clr-light: hsl(231, 77%, 90%);
    --clr-white: hsl(0, 0%, 100%);
    --clr-white-200: hsl(0, 0%, 80%);
    --clr-white-100: hsl(0, 0%, 50%);

    /* font sizes */

    --fs-900: 9.375rem;
    --fs-800: 6.25rem;
    --fs-700: 3.5rem;
    --fs-600: 2rem;
    --fs-500: 1.75rem;
    --fs-400: 1.125rem;
    --fs-300: 1rem;
    --fs-200: 0.875rem;

    /* font families */

    --ff-serif: "Bellefair", serif;
    --ff-sans-cond: "Barlow Condensed", sans-serif;
    --ff-sans-normal: "Barlow", sans-serif;

}


/* --------------------- */
/*        Reset          */
/* --------------------- */

/* 1. Use a more-intuitive box-sizing model */
*, 
*::before,
*::after {
  box-sizing: border-box;
}

/* 2. Remove default margin */
*:not(dialog) {
  margin: 0;
}

/* 3. Enable keyword animations */
@media (prefers-reduced-motion: no-preference) {
  html {
    interpolate-size: allow-keywords;
  }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1, !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}


/* 6. Improve media defaults */
picture, img, video, canvas, svg {
  display: block;
  max-width: 100%;
}

/* 7. Inherit fonts for form controls */
input, button, textarea, select {
  font: inherit;
}

/* 8. Reset margins */
body, h1, h2, h3, h4, h5, p, figure, picture, img {
  margin: 0;
  padding: 0;
}

/* 9. Improve line wrapping */
p {
  text-wrap: pretty;
}

h1, h2, h3, h4, h5, h6, p {
  font-weight: 400;
}


/* --------------------- */
/*    Utility class      */
/* --------------------- */

.flex {
    display: flex;
    gap: var(--gap, 1rem);
}

.flex-col {
    display: flex;
    flex-direction: column;
    gap: var(--gap, 1rem);
}


.grid {
    display: grid;
    gap: var(--gap, 1rem);
}

.container {
    padding: 2rem; 
    max-width: 80rem;
}

.display-block {
    display: block;
    
}

.flow > *:where(:not(:first-child)) {
    margin-top: var(--flow-space, 1rem);
    outline: 1px solid red;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/*  colors */

.bg-dark {
    background-color: var(--clr-dark);
}

.bg-accent {
    background-color: var(--clr-light);
}

.bg-white {
    background-color: var(--clr-white);
}

.text-dark {
    color: var(--clr-dark);
}

.text-gray {
    color: var(--clr-white-100)
}

.text-accent {
    color: var(--clr-light);
}

.text-white {
    color: var(--clr-white);
}

  /* Typography */

.ff-serif {
    font-family: var(--ff-serif);
}

.ff-sans-cond {
    font-family: var(--ff-sans-cond);
}

.ff-sans-normal {
    font-family: var(--ff-sans-cond)
}

.letter-spacing-1 {
    letter-spacing: 4.75px;
}

.letter-spacing-2 {
    letter-spacing: 2.7px;
}

.letter-spacing-3 {
    letter-spacing: 2.35px;
}

.uppercase {
    text-transform: uppercase;
}

.fs-900 {
    font-size: var(--fs-900);
}

.fs-800 {
    font-size: var(--fs-800);
}

.fs-700 {
    font-size: var(--fs-700);
}

.fs-600 {
    font-size: var(--fs-600);
}

.fs-500 {
    font-size: var(--fs-500);
}

.fs-400 {
    font-size: var(--fs-400);
}

.fs-300 {
    font-size: var(--fs-300);
}

.fs-200 {
    font-size: var(--fs-200);
}


.fs-900,
.fs-800,
.fs-700,
.fs-600 {
    line-height: 1.1;
}

.numbered-title {
    font-family: var(--ff-sans-cond);
    font-size: var(--fs-500);
    text-transform: uppercase;
    letter-spacing: 4.72px;
}

.numbered-title span {
    margin-right: 0.5em;
    font-weight: 700;
    color: var(--clr-white-100);
}


/* --------------------- */
/*     Components        */
/* --------------------- */


.large-button {
    display: inline-grid;
    place-items: center;
    aspect-ratio: 1;
    padding: 0 2em;
    border-radius: 50%;
    position: relative;
    z-index: 1;
    cursor: pointer;
}

.large-button > a {
    text-decoration: none;
    color: var(--clr-dark)
}

.large-button::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: var(--clr-white-200);
    z-index: -1;
    opacity: 0;
    transition: opacity 500ms linear, transform 750ms ease-in-out ;
}

.large-button:hover::after,
.large-button:focus::after {
    transform: scale(1.5);
    opacity: 1;
}

.underline-indicator > li > a {
    border: 0;
    padding: 1rem 0;
    cursor: pointer;
}

.underline-indicator > li > a:hover,
.underline-indicator > li > a:focus {
    border-color: hsl( var(--clr-white) / .25);
    border-bottom: .2rem solid var(--clr-white-200);
}



.underline-indicator > li > .active,
.underline-indicator > [aria-selected= "true"] {
    border-bottom: .2rem solid var(--clr-white);
    border-color: var(--clr-white);
    color: var(--clr-white);
}


.tab-list {
    /* --gap: 2rem; */
    font-size: var(--fs-200);
    padding-inline: 1.5rem;
    margin-bottom: 1rem;
}

.tab-list > button {
    background: transparent;
    border: none;
    cursor: pointer;
}

.tab-list > button > .active {
    color: orangered;
}

.tab-list > button >a:hover,
.tab-list > button >a:focus {
    color: orangered;
}


.dot-indicator > * {
    cursor: pointer;
    border: 0;
    border-radius: 50%;
    padding: .5em;
    background-color: var(--clr-white-100);
}

.dot-indicator > *:hover,
.dot-indicator > *.focus {
    background-color: var(--clr-white-200);
}

.dot-indicator > [aria-selected="true"] {
    background-color: var(--clr-white);
}

.numbered-indicator {
    height: clamp(2.5rem, 5vw, 5rem);
    width: clamp(2.5rem, 5vw, 5rem);
    display: grid;
    place-content: center;;
    cursor: pointer;
    border-radius: 50%;
    border: 1px solid var(--clr-white-100);
    background-color: var(--clr-dark);
    color: var(--clr-light);
    
}

.numbered-indicator:hover,
.numbered-indicator:focus {
    background-color: var(--clr-white);
    color: var(--clr-dark);
}

.numbered-indicator a {
    text-decoration: none;
    color: inherit;
    font-size: clamp(1rem, 2vw, 2rem);
    font-weight: 700;
}   

.numbered-indicator[aria-selected= "true"] {
    background-color: var(--clr-white);
    color: var(--clr-dark);
}

/* --------------------- */
/*   Background images   */
/* --------------------- */

body {
    background-size: cover;
    background-position: bottom center;

}

.home {
    background-image: url(./assets/home/background-home-mobile.jpg)
}

@media(min-width: 35rem) {
    .home {
        background-image: url(./assets/home/background-home-tablet.jpg);
        background-position: center center;
    }
}

@media(min-width: 49rem) {
    .home {
        background-image: url(./assets/home/background-home-desktop.jpg)
    }

}    
   /*   Destination Background   */ 

.destination {
    background-image: url(./assets/destination/background-destination-mobile.jpg);
    background-position: right top;
}

@media(min-width: 35rem) {
    .destination {
        background-image: url(./assets/destination/background-destination-tablet.jpg);
        background-position: center center;
        background-repeat: no-repeat;
        background-size: cover;
    }
}

@media(min-width: 49rem) {
    .destination {
        background-image: url(./assets/destination/background-destination-desktop.jpg);
        background-repeat: no-repeat;
        background-size: cover;
    }
   
}

/*   Crew Background   */

.crew {
    background-image: url(./assets/crew/background-crew-mobile.jpg)
}

@media(min-width: 35rem) {
    .crew {
        background-image: url(./assets/crew/background-crew-tablet.jpg);
    }
}

@media(min-width: 49rem) {
    .crew {
        background-image: url(./assets/crew/background-crew-desktop.jpg);
        background-repeat: no-repeat;
        background-size: cover;
    }
}

/*   Technology Background   */

.technology {
    background-image: url(./assets/technology/background-technology-mobile.jpg);

}

@media(min-width: 35rem) {
    .technology {
        background-image: url(./assets/technology/background-technology-tablet.jpg);
        background-repeat: no-repeat;
        background-size: cover; 
    }
}

@media(min-width: 49rem) {
    .technology {
        background-image: url(./assets/technology/background-technology-desktop.jpg);
        background-repeat: no-repeat;
        background-size: cover;
    }
}



body {
  line-height: 1.5;
  font-family: var(--ff-sans-normal); 
  font-size: var(--fs-400); 
  color: var(--clr-light);
  background-color: var(--clr-dark);
  min-height: 100vh;

  display: grid;
  grid-template-rows: min-content 1fr;

  overflow-x: hidden;

  -webkit-font-smoothing: antialiased;
}

/* --------------------- */
/*   Navigation bar      */
/* --------------------- */

.primary-header {
    justify-content: space-between;
    align-items: center;
}

.logo {                     
    width: clamp(2rem, 8vw, 3rem);
    height: clamp(2rem, 8vw, 3rem);
    margin: 1.5rem;
}

.primary-navigation {
    position: fixed;
    inset: 0 0 0 30%;
    list-style: none;
    margin: 0;
    padding: min(20rem, 15vh) 2rem;
    z-index: 1000;
    backdrop-filter: blur(1rem);
    -webkit-backdrop-filter: blur(2rem);
    gap: 3rem;
    transform: translateX(100%);
    transition: transform 600ms ease-in-out;
   
}

.primary-navigation a {
    text-decoration: none;
    
}


.primary-navigation a > span {
    margin-right: 0.3em;
    font-weight: 700;
}

.primary-navigation[data-visible="true"] {
    transform: translateX(0%);
}



.mobile-nav-toggle {
    width: 1.5rem;
    height: 1.3rem;
    position: absolute;
    top: 2rem;
    right: 1.5rem;
    display: block;
    aspect-ratio: 1;
    z-index: 2000;
    background: transparent;
    background-image: url(./assets/shared/icon-hamburger.svg);
    background-repeat: no-repeat;
    border: 0;
    cursor: pointer;
}

.mobile-nav-toggle[aria-expanded="true"] {
    background-image: url(./assets/shared/icon-close.svg);
}

@media(min-width: 35rem) {
   

    .primary-navigation {
    position: static;    
    flex-direction: row;
    justify-content: center;
    list-style: none;
    margin: 0;
    padding: 1rem 5rem;
    z-index: 0;
    backdrop-filter: blur(5rem);
    --gap: 2rem;

    -webkit-backdrop-filter: blur(5rem);  
    
    transform: none;
    transition: none;

  };

  
}


@media(min-width: 85rem) {
    .logo {
            width: 9rem;
        
        }

    .primary-header::after {
        content: '';
        position: relative;
        display: block;
        width: 80%;
        height: 1px;
        margin-right: -2rem;
        background: var(--clr-white-100);
        order: 1;
    }

    nav {
        order: 2;
    }

    .primary-navigation {
        --gap: 3rem;
        padding: 2rem;
        margin-block: 2rem;
        width: 60vw;
    }
}

@media(min-width: 35rem) {
    .mobile-nav-toggle {
        display: none;
    }
}
/* --------------------- */
/*    Main Content       */
/* --------------------- */

/*  Home page  */

.homepage-container {
    text-align: center;
}

.container-home {
    padding: 2rem;
    max-width: 80rem;
}

.homepage-title {
    font-size: var(--fs-400);
}

.homepage-title > span {
    font-size: 5rem;
}


.homepage-description {
    font-size: var(--fs-400);
}

.homepage-button {
    width: 9rem;
    height: 9rem;
    margin: 3rem auto;
}

@media(min-width: 35rem) {
    .homepage-container {
        margin-top: 6rem;

    }

    .homepage-content {
        max-width: 35rem;
        margin: auto;
        gap: 1.5rem;
    }

    .homepage-button-container {
        max-width: 35rem;
        margin: auto;
    }

    .homepage-button {
        width: 17rem;
        height: 17rem;
        font-size: 2rem;
    }

    .homepage-title {
       font-size: var(--fs-500); 
    }
    
    .homepage-title > span {
        font-size: 8rem;
    }
}


@media(min-width: 64rem) {
    .container-home {
        max-width: 100%;
        padding: 8rem;
    }

    .homepage-container {
        grid-template-columns: 1fr 1fr;
        margin: auto;
        width: 100%;
        height: 100%;
        max-width: 69.375rem;
        gap: 5rem;
    }
    
    .homepage-content {
        margin: auto;
        height: 39.5rem;
        display: flex;
        flex-direction: column;
        align-items: start;
        justify-content: flex-end;
        margin: 0;
        max-width: 33.75rem; 
    }

    .homepage-button-container {
        height: 39.5rem;
        width: 100%;
        display: flex;
        justify-content: flex-end;
        align-items: end;
    }

    .primary-navigation {
        min-width: 41.5rem;
    }
}

/*   Destination Page   */


.destination-container {
    text-align: center;
    max-width: 60ch;
    margin: 5rem auto;
    color: var(--clr-light);   
}

.destination-hero > picture {
    width: 45%;
    max-width: 60%;
    margin: 5rem auto;
    animation: rotate 20s linear infinite
}

.destination-content {
    justify-content: center;
    align-items: center;

}

.destination-info {
    padding: 0 1.5rem;
}

.numbered-title {
    font-size: var(--fs-300)
}

.tab-list > button > a {
    text-decoration: none;
    color: var(--clr-light);
    font-size: var(--fs-400);
}

.destination-info-moon {
    font-size: var(--fs-700); 
    margin-bottom: 1rem;
}

.destination-info-description {
    font-size: var(--fs-200);
    line-height: 1.8;
}

.destination-info-metadata {
    border-top: .5px solid var(--clr-white-100);
    margin-top: 2.5rem;
    padding-top: 2.5rem;
    
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}




@media(min-width: 35rem) {
    .numbered-title {
        text-align: start;
        font-size: 1.25rem;

    }

    .tab-list {
       padding-inline: 25% 25%;
       margin-bottom: 3rem;
       font-size: var(--fs-300);
       --gap: 2rem;
    }

    .destination-hero > picture { 
       margin: auto;
   }


    .destination-info-moon {
        font-size: 5rem;
    }

    .destination-info-metadata {
        flex-direction: row;
        justify-content: space-evenly;
        margin: 2.5rem auto;
        padding-top: 2.5rem;
    }
}

@media(min-width: 64rem) {
    .main-container-dest {
        padding: 3rem;
    }

   .destination-container {
        max-width: 90rem;
        grid-template-columns: 1fr 1fr ;
   }
    
   .destination-hero {
        display: flex;
        flex-direction: column;
        width: 100%
   }

   .destination-hero > picture {
        max-width: 70%;

   }

   .destination-content {
     text-align: start;
     align-items: start;
     width: 100%
   }

   .tab-list {
        padding: 0
   }

   .destination-info-metadata {
    justify-content: flex-start;
    gap: 6rem;
   }

    .destination-info-description {
        max-width: 27.8125rem;
   }
}

/*   Crew Page   */

.main-container-crew {
    padding: 2rem;
    gap: 0.5rem;
}

.numbered-title {
    text-align: center;
    margin-bottom: 2rem;
}

.crew-subcontainer {
    grid-template-rows: 1fr 1fr;
    text-align: center;
   
}

.crew-content { 
    gap: 3.5rem;
    align-items: center;
}


.crew-title-name {
    font-size: var(--fs-400);
}

.crew-title-name > p {
    font-size: 1.5rem;
}

.crew-description {
    font-size: var(--fs-200)
}


.crew-picture > picture > img {
    max-width: 70vw;
    max-height: 21.25rem;
    margin: auto;
}


@media(min-width: 35rem) {
    .container-crew {
        margin: auto;
        padding: 2.5rem 2.5rem 0 2.5rem;
    }

    .crew-container {
        max-width: 80vw;
       
    }

    .numbered-title {
        text-align: start;
        font-size: var(--fs-300);
    }

    .crew-subcontainer {
        grid-template-rows: 40% 60%;
        margin-top: 4rem;
    }

    .numbered-title {
        font-size: 1.25rem;
        text-align: start;
    }

    .crew-title-name > h1 {
        font-size: 1.5rem
    }

    .crew-title-name > p {
        font-size: 2.5rem
    }

   
   .crew-picture > picture > img {
    max-width: max-content;
    max-height: max-content;
    
   }

   .crew-description {
    max-width: 32rem;
    font-size: var(--fs-300);
    margin: auto
   }
}

@media(min-width: 64rem) {
    .main-container-crew {
        max-width: 100%;
        padding: 8rem;
    }

    .crew-subcontainer {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: none;
        gap: 8rem;
        text-align: start;
        align-items: center;
    }

    .crew-article-section {
        height: 100%;
        align-items: center;
    }

    .crew-content {
        height: 100%;
        align-items: start;
        justify-content: space-between;
        gap: 2rem;
    }

    .numbered-title {
        font-size: 2.5rem;
    }

    .crew-title-name > h1 {
        font-size: var(--fs-600);
    }

    .crew-title-name > p {
        font-size: var(--fs-700);
    }

    .crew-description {
        font-size: var(--fs-400);
        max-width: 27.8125rem;
        margin: 0;
    }

    .dot-indicator {
        --gap: 2.5rem;
    }


}

/*  Technology Page  */


.technology-subcontainer {
    text-align: center; 
}

 .numbered-title {
    font-size: var(--fs-300);
    margin: 2rem 0 4rem 0;
}

.technology-hero {
    max-width: 100vw;
    margin-bottom: 1rem;
}

.technology-hero > picture > img {
    height: 35vh;
    
}

.technology-numbered-buttons {
    margin: auto;
}

.tech-info-term {
    color: var(--clr-white-100);
    font-size: clamp(1.125rem, 2vw, 2rem);
}

.tech-info-equipment {
    font-size: clamp(1.5rem, 6vw, 3rem);
    margin-bottom: 1.5rem;
}

.technology-content {
    margin: 0 1rem 2.5rem
}

.tech-info-description {
    font-size: var(--fs-200)
}

@media(min-width: 35rem) {
     .numbered-title {
        text-align: start;
        font-size: 1.25rem;
        margin: 2rem;
    }

    .technology-hero > picture > img {
        height: 45vh;
    }

    .technology-content {
        max-width: 60%;
        margin: auto;
    }

    .techno-info-term {
        font-size: 1.5rem;
    }

    
}


@media(min-width: 64rem) {
    .numbered-title {
        font-size: 1.75rem;
        margin: 2rem 0 4rem 12rem;
    }

    .technology-subcontainer {
        grid-template-columns: 55% 45%;

    }

    .technology-hero {
        order: 2;
        max-width: 100%;
        margin: 0;
        display: flex;
        justify-content: flex-end;
    }

    .technology-hero > picture > img {
        height: 60vh;

    }

    .technology-content {
        max-width: 100%;
        flex-direction: row;
        gap: 4rem;
        margin-left: 12rem;
    }

    .tech-info {
        text-align: left;
        margin: 0;
    }

   
    .tech-info-description {
        font-size: var(--fs-300);
    }

    .technology-numbered-buttons {
        flex-direction: column;
        gap: 2rem;
        margin: 0;
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg)
    }
    to {
        transform: rotate(360deg)
    }
}