body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    background-color: #f4f4f4;
    color: #333;
}

header {
    background: #004d99;
    color: #fff;
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 2000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    max-height: 58px;
    margin: auto;
    padding: 0 1rem;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
}

.logo {
    transform: scale(0.6) ;
}

.hero {
    background-image: url(imagenes/princ.png);
    background-size: cover;
    background-position: center;
    color: #fff;
    align-content: center;
    padding: 35rem 1rem 20rem 1rem;
}

.hero h1 {
    font-size: 2.3rem;
    text-shadow: 5px 5px 4px #000, -5px 5px 4px #000;
}

.hero p {
    text-shadow: 5px 5px 4px #000;
}

.btn {
    display: inline-block;
    background: #ff5722;
    color: #fff;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 1rem;
    margin-left: 15rem;
}

section {
    padding: 4rem 1rem;
    max-width: 1200px;
    margin: auto;
    height: 200%;
}

.box-serv {
    padding: 25rem 1rem 18rem 1rem;
    background-image: url(imagenes/princ2.png);
    object-position: top right;
    background-size: cover;
    
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.servicio {
    background: #fff;
    padding: 0.5rem;
    text-align: center;
    border-radius: 8px;
    box-shadow: 5px 5px 10px #000;
    overflow: hidden;
}

.box-serv h2 {
    color: #222;
    font-size: 2.5rem;
    text-shadow: 3px 3px 3px #fff, -3px 3px 3px #fff, 3px -3px 3px #fff;
}

.servicio img {
    height: 150px;
    width: 150px;
    object-fit:contain;
}

.p-costo {
    font-weight: bold;
    font-size: 1.2rem;
    color: #031b00;
}

.box-domo {
    color: #000;
    background-image: url(imagenes/domo.png);
    background-size: cover;
    font-size: 1.3rem;
    text-shadow: 1px 1px 3px #fff;
    padding: 35rem 1rem 20rem 1rem;
}

.box-contact {
    align-content: center;
    padding: 10rem 1rem 10rem 1rem;
}

form {
    display: grid;
    gap: 1rem;
    max-width: 600px;
    margin: auto;
}

form .btn {
    background-color: #ff5722;
    width: 100%;
    margin: 20px 10px 0px 10px;
}

input, textarea {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #9204ff;
    border-radius: 5px;
}

footer {
    background: #333;
    color: #fff;
    text-align: center;
    padding: 1rem 0;
}

@media screen and (max-width: 470px) {
    header {
        position: sticky;
        top: 0;
        padding: 0;
        height: 90px;
    }

    section {
        height: auto;
    }

    .hero .btn {
        margin-left: 35%;
    }

    .hero {
        background-position: 70%;
        align-content: start;
        padding-top: 150px;
    }

    .hero p {
        margin-top: 60%;
        text-align: center;
        font-size: 20px;
    }

    .box-serv {
        background-position: 50%;
        padding-top: 15%;
        height: auto;
    }

    .box-domo {
    background-size: cover;
    background-position: center;
    height: auto;
    color: #fff;
    text-shadow: 2px 2px 2px #000;
    padding-top: 200px;
    }
    .box-contact {
        align-content: start;
        height: auto;
        padding-top: 10px 0 0px 0;
    }

    .box-contact .btn {
        margin: 0;
        margin-top: 10%;
    }

    input, textarea {
    width: 95%;
    box-shadow: 5px 5px 10px #444;
    }
    .logo{
        position: absolute;
        padding-top: 10px;
        transform: scale(0.4);
    }
    nav {
    display: flex;
    justify-content: center;
    }
    ul {
        padding: 0;
        padding-top: 88px;
    }

    .servicios-grid {
        margin-top: 3%;
    }

    .caracteristicas-domotica ul li {
        list-style-type: none;
    }

}