/* Reset some default styles */
body,
h1,
h2,
h3,
p,
ul,
li,
img,
a,
button {
    margin: 0;
    padding: 0;
    list-style: none;
    text-decoration: none;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    line-height: 1.6;
    color: white;
    /* Cor do texto em modo noturno */
    background-color: #12171C;
    /* Cor de fundo para modo noturno */
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Variáveis de cores */
:root {
    --primary-color: #0A2741;
    /* Cor primária (azul) */
    --light-background: #2b2a2a;
    /* Cor de fundo clara */
    --text-color: white;
    /* Cor do texto */
    --border-color: #676767;
    /* Cor da borda */
    --button-color: #1565C0;
    /* Cor do botão */
    --link-background-1: #0A2741;
    /* Fundo opaco 1 */
    --link-background-2: rgba(72, 1, 36, 0.3);
    /* Fundo opaco 2 */
    --link-background-3: rgba(0, 98, 49, 0.3);
    /* Fundo opaco 3 */
}

/* Estilos para o header */
header {
    background-color: var(--primary-color);
    color: white;
    padding: 0;
    text-align: center;
    border-radius: 10px;
    position: relative;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
}

.icone {
    width: 100px;
    height: 100px;
    margin: 0px;
    padding: 0px;
}

.chat-icon {
    font-size: 1.5rem;
    /* Tamanho do ícone */
    cursor: pointer;
    /* Cursor ao passar por cima */
    margin-right: 20px;
    /* Espaçamento à direita para separar do canto */
    margin-top: 10px;
    /* Espaçamento acima */
    color: white;
    /* Cor do ícone */
    position: absolute;
    /* Posicionamento absoluto */
    top: 110px;
    /* Distância do topo */
    right: 10px;
    /* Distância da direita */
}

/* Estilos para a lista de links */
.nav-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    padding: 10px;
    background-color: black;
    flex-wrap: wrap;
}

.nav-links a {
    color: white;
    font-size: 0.9rem;
    /* Fonte menor */
    font-weight: 250;
    /* Letra mais fina */
    padding: 0.5rem 1rem;
    text-transform: uppercase;
    transition: 0.3s ease;
}

.nav-links a:hover {
    color: rgb(133, 133, 133);
    /* Cor mais escura ao passar o mouse */
}

/* Estilos para o conteúdo principal */
main {
    padding: 2rem;
}

.hero p {
    margin-bottom: 20px;
}

.start-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

/* Estilos para os cartões de perfil */
.profiles {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: space-around;
    /* Alinhamento dos cartões */
}

.profile-cards {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    /* Tornar rolável horizontalmente */
    overflow-y: hidden;
    /* Ocultar rolagem vertical */
    white-space: nowrap;
    /* Garantir que os cartões fiquem em uma linha */
    padding-bottom: 1rem;
    /* Espaçamento na parte inferior para melhorar visualização */
}


.profile-card {
    background: var(--light-background);
    border: 1px solid var(--border-color);
    padding: 1rem;
    width: 300px;
    box-sizing: border-box;
    text-align: center;
    border-radius: 10px;
    margin-right: 1rem;
    display: inline-block;
}



.profile-card img {
    max-width: 100%;
    width: 100%;
    height: 40%;
    /* Adicionando height para manter proporção */
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 1rem;
    object-fit: cover;
}

.profile-card h3 {
    font-size: 1.5rem;
    margin: 0.5rem 0;
    overflow: hidden;
    /* Evitar que o texto vaze do card */
    text-overflow: ellipsis;
    /* Adicionar reticências se o texto for muito longo */
    white-space: nowrap;
    /* Evitar que o texto quebre linha */
}

.profile-card p {
    font-size: 1rem;
    margin-bottom: 1rem;
    /* Espaço abaixo do parágrafo */
    overflow: hidden;
    /* Evitar que o texto vaze do card */
    text-overflow: ellipsis;
    /* Adicionar reticências se o texto for muito longo */
    white-space: nowrap;
    /* Evitar que o texto quebre linha */
}

.posts,
.profiles {
    margin-top: 50px;
}

.posts h2 {
    display: flex;
    justify-content: center;
}

/* Estilos para os posts */
.posts {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.posts .post {
    background: var(--light-background);
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    margin-bottom: 2.5rem;
    border-radius: 10px;
    margin-top: 12px;
    width: 100%;
    max-width: 600px;
    box-sizing: border-box;
}

.posts .post h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.post {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-left: 10px;
    margin-right: 10px;
    flex-wrap: wrap;
    gap: 12px;
}

.user-info {
    display: flex;
    margin-bottom: 10px;
    width: 100%;
}

.user-info img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
}

.username {
    font-weight: bold;
    margin: 0;
    font-size: 17px;
    margin-top: 5px;
}

.post-photo {
    display: flex;
    border-radius: 10px;
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* Estilos para botões */
button {
    background: var(--button-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease;
    border-radius: 10px;
    box-shadow: 0px 5px 5px black;
}

button:hover {
    background: #347ed3;
    /* Cor do botão ao passar o mouse */
}

.ver-mais {
    display: flex;
    justify-content: center;
}

.about-me h2 {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.devs {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
    gap: 100px;
    margin: 40px;
}

.dev img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
}

.dev {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 7px;
}

/* Estilos para o rodapé */
footer {
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    padding: 1rem 0;
    border-radius: 10px;
    margin-top: 2rem;
}

/* Chat Dialog Styles */
.chat-dialog {
    display: none;
    position: fixed;
    bottom: 0;
    right: 20px;
    width: 300px;
    max-width: 90%;
    background-color: var(--light-background);
    border: 1px solid var(--border-color);
    border-radius: 10px 10px 0 0;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.chat-dialog.open {
    display: block;
}

.chat-header {
    background-color: var(--primary-color);
    color: white;
    padding: 10px;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    margin: 0;
    font-size: 1rem;
}

.chat-body {
    padding: 10px;
    max-height: 300px;
    overflow-y: auto;
    background-color: var(--light-background);
}

.chat-footer {
    display: flex;
    border-top: 1px solid var(--border-color);
}

.chat-footer input[type="text"] {
    flex-grow: 1;
    border: none;
    padding: 10px;
    border-radius: 0 0 0 10px;
}

.chat-footer button {
    border: none;
    padding: 10px;
    background-color: var(--button-color);
    color: white;
    cursor: pointer;
    border-radius: 0 0 10px 0;
}

/* Media Queries para dispositivos menores */
@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        align-items: center;
    }

    .hero {
        text-align: center;
    }

    .hero p {
        font-size: 1rem;
    }

    .profiles,
    .posts {
        flex-direction: column;
        align-items: center;
    }

    .profile-card {
        width: 80%;
    }

    .posts .post {
        width: 90%;
        margin: 0 auto 2rem;
    }

    .user-info {
        flex-direction: column;
        align-items: center;
    }

    .user-info img {
        margin-bottom: 10px;
    }

    .username {
        text-align: center;
        margin-right: 0;
    }

    .post-photo {
        width: 100%;
        height: auto;
    }

    .chat-icon {
        font-size: 1.2rem;
    }

    .chat-dialog {
        width: 90%;
        right: 5%;
    }

    .dev img {
        width: 150px;
        height: 150px;
    }

    .dev {
        gap: 5px;
    }
}

/* Alinhamento centralizado para posts no desktop */
@media (min-width: 769px) {
    .posts {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
}

/* Ajuste para dispositivos menores */
@media (max-width: 768px) {
    .profile-card {
        width: calc(50% - 0.5rem);
        /* Ajuste fino na largura, descontando um pouco menos para evitar quebras de linha */
        margin-bottom: 1rem;
        /* Reduzir espaço inferior entre os cards */
    }

    .profile-card img {
        width: 100%;
        /* A imagem ocupa toda a largura do card */
        height: auto;
        /* A altura é ajustada automaticamente */
        border-radius: 10px;
    }

    .profile-card h3 {
        font-size: 1.2rem;
        /* Reduzir o tamanho da fonte do título */
    }

    .profile-card p {
        font-size: 0.9rem;
        /* Reduzir o tamanho da fonte do texto */
    }
}
