* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f7f7f7;
    color: #333;
    line-height: 1.6;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 30px; /* Barra mais fina */
    background-color: rgba(0, 51, 102, 0.7); /* Transparente */
    position: fixed;
    width: 100%;
    z-index: 10;
    transition: background-color 0.3s ease, padding 0.3s ease;
}

header .logo img {
    max-width: 150px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
}

nav a:hover {
    color: #ffe600;
}

#hero-carousel {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.carousel-slide img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    display: none;
}

.carousel-slide img:first-child {
    display: block;
}

.carousel-caption {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    text-align: center;
    background-color: rgba(0, 0, 0, 0.5); /* Fundo mais escuro para destaque */
    padding: 20px;
    border-radius: 8px;
    width: 80%; /* Maior largura para o texto */
}

.carousel-caption h1 {
    font-size: 2.5em; /* Título maior */
    margin-bottom: 10px;
}

.carousel-caption p {
    font-size: 1.2em; /* Parágrafo maior */
    margin-bottom: 20px;
}

.cta-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #003366;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 20px;
    font-size: 1.1em;
}

.cta-button:hover {
    background-color: #002244;
}

.section-content {
    padding: 50px 20px;
    max-width: 1200px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0px 0px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
}

.section-content h2 {
    text-align: center;
    color: #003366;
    margin-bottom: 20px;
    font-size: 2em;
}

.section-content p {
    text-align: center;
    margin-bottom: 20px;
    font-size: 1.1em;
}

.image-small {
    max-width: 30%;
    margin: 20px auto;
    display: block;
    border-radius: 8px;
}

#servicos {
    text-align: center;
}

.service-container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 20px;
}

.service-box {
    width: 30%;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-box img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
    max-height: 150px;
    margin-bottom: 15px;
}

.service-box h3 {
    color: #003366;
    margin-bottom: 10px;
}

.service-box p {
    color: #555;
}

#contato form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 600px;
    margin: 0 auto;
}

#contato input, #contato textarea {
    padding: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
}

#contato button {
    padding: 15px;
    background-color: #003366;
    color: white;
    border: none;
    cursor: pointer;
    font-size: 16px;
    border-radius: 5px;
}

#contato button:hover {
    background-color: #002244;
}

footer {
    text-align: center;
    padding: 20px;
    background-color: #003366;
    color: white;
}

/* Navbar ajustando ao rolar a página */
window.addEventListener('scroll', function() {
    const navbar = document.getElementById('navbar');
    if (window.scrollY > 50) {
        navbar.style.backgroundColor = '#003366'; /* Cor sólida ao rolar */
        navbar.style.padding = '3px 30px'; /* Mais fina */
    } else {
        navbar.style.backgroundColor = 'rgba(0, 51, 102, 0.7)'; /* Transparente no topo */
        navbar.style.padding = '5px 30px'; /* Mais fina no topo também */
    }
});
