* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
  height: 100%;
}
body{
    background-color: rgb(31, 31, 31);
    font-family: 'Poppins', sans-serif;
    display: flex;
    flex-direction: column;
}

#header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: rgba(64, 0, 104, 0.45);
    box-shadow: 0 4px 6px rgba(90, 0, 146, 0.7);
}

#header img{
    height: 55px;
    padding: 2px 100px;
}

#bar {
    height: 75px;
    display: flex;
    align-items: center;
    position: relative;
    padding-right: 130px;
}

/* Menu esquerdo */
#bar > ul {
    list-style: none;
    display: flex;
    gap: 25px;
}

/* Itens principais */
#bar > ul > li {
    position: relative;
    text-transform: uppercase;
    font-size: 14px;
    display: flex;
    align-items: center;
}

/* Links do menu */
#bar > ul > li > a {
    display: block;
    padding: 15px 15px; /* adiciona lateral */
    text-decoration: none;
    color: white;
    transition: color 0.2s ease;
}

/* Hover texto */
#bar > ul > li:hover > a {
    color: #949393;
}

/* Linha animada */
#bar > ul > li:not(:has(button))::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 8px;
    width: 0;
    height: 2px;
    background: black;
    transition: width 0.3s ease;
}

#bar > ul > li:not(:has(button)):hover::after {
    width: 100%;
}

/* Submenu */
.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background-color: rgb(42, 0, 68);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    list-style: none;

    padding: 5px 0; /* só vertical */
}

/* Mostrar */
.servicos:hover .submenu {
    display: block;
}

/* Cada item */
.submenu li {
    width: 100%;
}

/* Link */
.submenu li a {
    display: block;
    width: 100%;
    padding: 10px 15px; /* padding só aqui */
    font-size: 14px;
    text-decoration: none;
    color: white;
    text-align: left;
}
.submenu li a:hover {
    color: #b6b6b6;
}
/* Hover */
.submenu li:hover {
    background-color: rgb(33, 0, 54);
}
#bar > ul > li:hover > a {
    color: #b6b6b6; /* cinza */
}

button {
    display: block;
    font-family: 'Montserrat';
    text-transform: uppercase;
    background-color: rgb(64, 0, 104);
    color: rgb(255, 255, 255);
    border: none;
    padding: 7px 30px;
    border-radius: 30px;
    cursor: pointer;

    transition: transform 0.15s ease; /* animação suave */
}

button:hover {
    background-color: rgb(33, 0, 54);
    transform: scale(0.93); /* diminui */
    text-decoration: none;
}

#conteudo2 {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: white;
    text-align: center;
    padding: 40px 20px;
    border-radius: 30px;

    max-width: 900px;
    margin: 40px auto;

    background-color: rgba(64, 0, 104, 0.5);
    box-shadow: 0 10px 30px rgba(64, 0, 104, 0.7); /* dá profundidade */
    backdrop-filter: blur(1px);
    border: 1px solid rgb(95, 11, 95);
}

#conteudo2 h1 {
    font-size: 28px;
    margin-bottom: 10px;
}

#conteudo2 h2 {
    font-size: 16px;
    font-weight: 400;
    opacity: 0.9;
}
#conteudo2 button{
    background: linear-gradient(145deg, #7b30c2, #4b0688);
    margin-top: 30px;
    padding: 20px 30px;
}
#conteudo3 {
    display: flex;
    flex-wrap: wrap; /* quebra linha */
    justify-content: center; /* centraliza */
    gap: 20px; /* espaço entre cards */
    margin-top: 60px;
}
.card {
    width: 300px; /* fixa largura melhor que max-width */
    background: linear-gradient(145deg, rgb(90, 20, 140), rgb(64, 0, 104));
    border: 2px solid rgb(64, 0, 104);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}
.card i {
    font-size: 30px;
    margin: 15px 0;
    color: rgb(182, 74, 250);
}
.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgb(64, 0, 104);
}
.card p {
    color: #ffffff;
    margin-bottom: 10px;
    opacity: 0.9;
}
.card h1,
.card h2,
.card h3 {
    color: #ffffff;
    margin-bottom: 10px;
}

#portifolio {
    padding: 30px;
    color: white;
    margin-top: 60px;
}

/* títulos */
.tituloPortifolio {
    text-align: center;
    margin-bottom: 40px;
}

/* container dos cards */
.cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}
.cardImg button {
    display: block;
    margin: 20px auto 0 auto;
    padding: 15px 25px;
    background: linear-gradient(145deg, #7b30c2, #4b0688);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
}
.cardImg {
    width: 380px; /* fixa largura melhor que max-width */
    background: linear-gradient(145deg, rgb(90, 20, 140), rgb(64, 0, 104));
    border: 2px solid rgb(64, 0, 104);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    margin-top: 30px;
}
.cardImg i {
    font-size: 30px;
    margin: 15px 0;
    color: rgb(182, 74, 250);
}
.cardImg:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgb(64, 0, 104);
}
.cardImg p {
    color: #ffffff;
    margin-bottom: 10px;
    opacity: 0.9;
    font-size: 17px;
}
.cardImg img {
    width: 100%;
    height: 200px; /* altura fixa */
    object-fit: cover; /* corta sem deformar */
    border-radius: 8px;
    margin-bottom: 15px;
}
.cardImg h1,
.cardImg h2,
.cardImg h3 {
    color: #ffffff;
    font-size: 20px;
    margin-bottom: 10px;
}

#CTA{
    display: flex;
    flex-direction: column;
    align-items: center;
    color: white;
    text-align: center;
    padding: 20px 20px;
    border-radius: 30px;
    max-width: 900px;
    margin: 40px auto;
    border: 2px solid rgb(64, 0, 104);
}
#CTA button{
    margin-top: 30px;
    padding: 20px 40px;
}

#rodape {
  background-color: rgba(35, 1, 56, 0.575);
  color: #ffffff;
  padding: 15px;
  margin-top: 100px;
  text-align: center;
  width: 100%;
}
#rodape a {
    color: #ffffff;
    text-decoration: none;
    margin: 0 10px;
}
#rodape a:hover {
    text-decoration: underline;
}