@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');
@import url('https://fonts.cdnfonts.com/css/star-wars');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    text-decoration: none;
    list-style: none;
    color: white;
}

body {
    background-image: url('../img/fundoEstelar.jpg');
    background-size: cover;
    height: 100vh;
}

header {
    display: flex;
    align-items: center;
    justify-content: space-around;
}

.logo {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 350px;
    height: 100%;
}

.logo-img {
    width: 40%;
    height: auto;
}

.logo-text {
    font-family: 'Star Wars', sans-serif;
    font-size: 1.2rem;
}

.social-media {
    display: flex;
    justify-content: space-between;
    width: 150px;
}

i {
    font-size: 1.2rem;
}

i:hover {
    color: gold;
}

.main-container {
    display: flex;
    align-items: center;
    flex-direction: column;
    width: 100%;
    padding: 20px 0;
}

h2 {
    font-family: 'Star Wars', sans-serif;
    margin-bottom: 20px;
    color: gold;
    font-weight: 300;
}

.main-content {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    column-gap: 20px;
    row-gap: 20px;
}

.cards {
    display: flex;
    align-items: end;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.5s;
    padding: 5px;
    width: 266px;
    height: 400px;
    background-position: 50% 50%;
    background-size: cover;
}

cards:hover {
    transform: scale(1.02);
}

.character-name-bg {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    width: 100%;
    height: 30px;
    background-color: rgba(0, 0, 0, 0.6);
}

.character-name {
    font-family: 'Star Wars', sans-serif;
    color: gold;
    font-size: 1rem;
    text-align: center;
}

.buttons {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    width: 60%;
}

button {
    width: 100px;
    height: 30px;
    background-color: gold;
    color: black;
    font-weight: 700;
    border-radius: 3px;
    cursor: pointer;
    border: 1px solid #000;
    outline: none;
    transition: 0.3s;
}

button:hover {
    background-color: #000;
    color: gold;
}

#back-button {
    visibility: hidden;
}

footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    row-gap: 10px;
    margin: 40px 0 20px 0;
    width: 100%;
}

.footer-logo {
    font-family: 'Star Wars', sans-serif;
    font-size: 1.5rem;
    font-weight: 500;
}

.copyrigth {
    font-weight: 500;
}

.modal-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.6);
    position: fixed;
    top: 0;
    visibility: hidden;
}

.modal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    row-gap: 15px;
    padding: 30px 10px;
    width: 25vw;
    height: 65vh;
    background-color: #0d0d0d;
    border-radius: 10px;
}

.character-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-position: 50% 10%;
    background-size: cover;
}

.character-details {
    font-family: 'Star Wars', sans-serif;
    font-size: 1rem;
    color: gold;
}

.social-media-footer {
    display: none;
}

/* Notebook */
@media (max-width: 1450px) {
    .cards {
    width: 170px;
    height: 255px;
    }
    .character-name {
        font-size: 0.75rem;
    }
    .character-image {
        width: 150px;
        height: 150px;
    }
    .character-details {
        font-size: 0.75rem;
    }
}

/* Tablet */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: repeat(3, 1fr);
    }
    .cards {
        width: 200px;
        height: 300px;
    }
    h2 {
        font-size: 1.2rem;
    }
    button:hover {
        background-color: gold;
        color: #000;
    }
    .character-image {
        width: 250px;
        height: 250px;
    }
    .character-details {
        font-size: 1.2rem;
    }
    .modal-content {
    width: 70vw;
    height: 50vh;
    }
}

/* Smartphone Retrato*/
@media (max-width: 768px) {
    .logo-img {
        width: 30%;
    }
    .logo-text {
        font-size: 1rem;
    }
    .social-media {
        display: none;
    }
    .main-content {
        grid-template-columns: repeat(2, 1fr);
    }
    .cards {
        width: 150px;
        height: 225px;
    }
    h2 {
        font-size: 1rem;
        text-align: center;
    }
    button {
        width: 80px;
        height: 25px;
    }
    .footer-logo {
        font-size: 1.2rem;
    }
    .copyrigth {
        font-size: 1rem;
    }
    .social-media-footer {
        display: flex;
        flex-direction: column;
    }
    a, i{
        font-size: 1rem;
    }
    i:hover {
        color: white;
    }
    button:hover {
        background-color: gold;
        color: #000;
    }
    .modal-content {
    width: 70vw;
    height: 45vh;
    }
    .character-image {
        width: 150px;
        height: 150px;
    }
    .character-details {
        font-size: 0.75rem;
    }
}
