/* RESET E BASE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-image: 
        linear-gradient(135deg, rgba(224, 242, 254, 0) 0%, rgba(247, 250, 252, 0) 100%),
        url("Imagens/imagens-dev-cibersec.png");
    background-repeat: no-repeat;
    background-position: center center;
    background-attachment: fixed;
    background-size: cover;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #f1f5e9;
    line-height: 1.6;
}

/* LINKS */
a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover, a:focus {
    color: #1e40af;
    outline: none;
}

/* HEADER */
header {
    background: #1e293b;
    color: #f1f5e9;
    padding: 1.5rem 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    box-shadow: 0 4px 15px rgba(30,41,59,0.6);
    position: sticky;
    top: 0;
    z-index: 9999;
}

.header-container {
    overflow: hidden; 
    flex-grow: 1; 
}

header h1 {
    font-size: 2.1rem;
    font-weight: 800;
    letter-spacing: 0.12rem;
    white-space: nowrap;
    user-select: none;
    animation: scroll-left 12.5s linear infinite; 
    transform: translateX(100%);
}

@keyframes scroll-left {
    0% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(-100%);
    }
}

/* NAVEGAÇÃO */
nav {
    display: flex;
    gap: 20px;
}

nav a {
    font-weight: 600;
    font-size: 1.2rem;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.25s ease;
}

nav a:focus,
nav a:hover {
    color: #3b82f6;
    outline-offset: 3px;
    outline-color: #3b82f6;
}

/* BOTÃO MENU MOBILE */
#menu-toggle {
    display: none;
    font-size: 2rem;
    background: none;
    border: none;
    color: #f1f5e9;
    cursor: pointer;
    transition: transform 0.3s ease;
}

#menu-toggle:hover {
    transform: scale(1.1);
}

/* MAIN CONTENT */
main {
    max-width: 1080px;
    margin: 3rem auto 4rem;
    padding: 0 20px;
}

/* SEÇÕES */
section {
    margin-bottom: 3.5rem;
    padding: 2rem 0;
}

.section-fade {
    opacity: 0;
    transform: translateY(15px);
    animation: fadeSlideIn 1s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.section-fade.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.45s; }
.delay-4 { animation-delay: 0.6s; }
.delay-5 { animation-delay: 0.75s; }

@keyframes fadeSlideIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* TIPOGRAFIA */
h2 {
    font-size: 2.4rem;
    border-bottom: 4px solid #3b82f6;
    padding-bottom: 0.6rem;
    margin-bottom: 1.2rem;
    color: #3b82f6; 
    font-weight: 700;
    user-select: none;
}

h3 {
    font-size: 1.6rem;
    margin-bottom: 0.8rem;
    color: #1e293b;
    font-weight: 700;
}

p {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #f1f5e9;
    line-height: 1.65;
}

ul {
    list-style-position: inside;
    margin-bottom: 1.4rem;
}

ul li {
    margin-bottom: 0.7rem;
    font-size: 1.25rem;
    color: #475569;
}

.highlight {
    color: #3b82f6;
    font-weight: 700;
}

.process-list li {
    color: white !important;
    margin-bottom: 1rem;
    padding-left: 1rem;
}

#equipe ul li {
    color: white !important;
}

/* SERVIÇOS */
.services-list {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    justify-content: center;
    margin-bottom: 3.5rem;
}

.service-item {
    background: rgb(255, 255, 255);
    border-radius: 14px;
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        0 10px 15px -3px rgba(59, 130, 246, 0.3);
    flex: 1 1 280px;
    padding: 28px 22px;
    border: 3px solid transparent;
    transition:
        transform 0.35s ease,
        border-color 0.35s ease,
        box-shadow 0.35s ease;
    cursor: pointer;
    outline-offset: 3px;
    background-color: #1e293b;
}

.service-item:hover,
.service-item:focus {
    transform: translateY(-8px);
    border-color: #3b82f6;
    box-shadow:
        0 4px 12px rgba(59, 130, 246, 0.4),
        0 14px 25px -5px rgba(59, 130, 246, 0.55);
    outline: none;
}

.service-item h3,
.service-item p {
    color: #f1f5e9;
}

.service-item p {
    font-size: 1.4rem;
}

/* BACKGROUNDS DOS SERVIÇOS */
.service-item.dev-sites {
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)),
        url('Imagens/programadores programando 3.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-item.pentest {
    background-image:
        linear-gradient(rgba(0,0,0,0.48), rgba(0,0,0,0.48)),
        url('Imagens/pentesters 3.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-item.analise-falhas {
    background-image:
        linear-gradient(rgba(0,0,0,0.48), rgba(0,0,0,0.48)),
        url('Imagens/Consultores de Segurança da Informação.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-item.mitigacao-riscos {
    background-image:
        linear-gradient(rgba(0,0,0,0.48), rgba(0,0,0,0.48)),
        url('Imagens/programadores programando 4.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-item.consultoria-seguranca {
    background-image:
        linear-gradient(rgba(0,0,0,0.48), rgba(0,0,0,0.48)),
        url('Imagens/Consultores de Segurança da Informação 2.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.service-item.dev-apps {
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.48), rgba(0, 0, 0, 0.48)),
        url("Imagens/Desenvolvedores-de-apps.png"),
        url("Imagens/desenvolvedores-de-apps.png"),
        url("Imagens/programadores programando 3.jpg");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: #1e293b;
}

/* DESAFIOS/EQUIPE */
.challenges.equipe-fundo {
    background-image:
        linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('Imagens/equipe-desenvolvedores.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 14px;
    box-shadow: 0 6px 30px rgba(0,0,0,0.2);
    padding: 40px 50px;
    color: #f1f5e9;
}

.challenges.equipe-fundo ul li {
    color: #f1f5e9;
    font-size: 1.35rem; 
    padding: 0.5rem 0;
}

.process-list {
    margin-left: 28px;
    margin-bottom: 20px;
}

/* CARDS DE CONTATO */
.contact-info {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 30px;
}

.contact-card {
    background: rgba(30, 41, 59, 0.9);
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    flex: 1 1 300px;
    max-width: 400px;
    text-align: center;
    border: 2px solid #3b82f6;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(59, 130, 246, 0.4);
}

.contact-card h3 {
    color: #3b82f6;
    margin-bottom: 20px;
    font-size: 1.8rem;
}

.contact-card p {
    margin: 0;
    font-size: 1.3rem;
}

.contact-card a {
    color: #ffffff;
    text-decoration: none;
    font-size: 1.3rem;
    font-weight: 600;
    transition: color 0.3s ease;
    display: inline-block;
    padding: 10px 20px;
    border-radius: 8px;
    background: rgba(59, 130, 246, 0.1);
}

.contact-card a:hover {
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.2);
}

/* WHATSAPP FLOAT BUTTON E BALLOON */
.whatsapp-float {
    position: fixed !important;
    bottom: 20px !important;
    right: 20px !important;
    z-index: 1000 !important;
    transition: transform 0.3s ease;
    display: block !important;
    width: 60px !important;
    height: 60px !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
    text-decoration: none !important;
}

.whatsapp-float:hover {
    transform: scale(1.1) !important;
}

.whatsapp-float img {
    width: 60px !important; 
    height: 60px !important;
    border-radius: 50% !important;
    display: block !important;
    object-fit: cover !important;
}

.whatsapp-balloon {
    position: absolute !important;
    right: 75px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: #25d366 !important;
    color: white !important;
    padding: 12px 16px !important;
    border-radius: 20px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4) !important;
    z-index: 1001 !important;
    font-family: 'Segoe UI', Arial, sans-serif !important;
    opacity: 1 !important;
    visibility: visible !important;
    animation: pulseBalao 3s infinite ease-in-out !important;
    pointer-events: none !important;
    display: block !important;
}

.whatsapp-balloon::after {
    content: '' !important;
    position: absolute !important;
    right: -8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 0 !important;
    height: 0 !important;
    border-left: 8px solid #25d366 !important;
    border-top: 8px solid transparent !important;
    border-bottom: 8px solid transparent !important;
}

@keyframes pulseBalao {
    0%, 100% { 
        transform: translateY(-50%) scale(1);
        box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    }
    50% { 
        transform: translateY(-50%) scale(1.05);
        box-shadow: 0 6px 16px rgba(37, 211, 102, 0.6);
    }
}

.whatsapp-float:hover .whatsapp-balloon {
    background: #20c55e !important;
    transform: translateY(-50%) scale(1.08) !important;
    animation-play-state: paused !important;
}

/* FOOTER */
footer {
    background-color: #1e293b;
    color: #cbd5e1;
    text-align: center;
    padding: 25px 20px;
    font-size: 1rem;
    box-shadow: 0 -3px 14px rgba(30, 41, 59, 0.7);
    user-select: none;
}

/* ACESSIBILIDADE */
*:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

img[src=""] {
    display: none;
}

/* RESPONSIVIDADE */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        text-align: center;
        padding: 1rem 1.5rem;
    }
    
    .header-container {
        width: 100%;
        text-align: center;
    }

    header h1 {
        font-size: 1.8rem;
    }

    nav {
        flex-direction: column;
        gap: 12px;
        margin-top: 12px;
        display: none; 
        width: 100%;
    }

    nav.active {
        display: flex;
    }

    nav a {
        font-size: 1.1rem;
        padding: 0.8rem;
        border-radius: 8px;
        background: rgba(59, 130, 246, 0.1);
        text-align: center;
    }

    #menu-toggle {
        display: block;
        position: absolute;
        top: 1rem;
        right: 1.5rem;
    }

    main {
        padding: 0 15px;
        margin: 2rem auto 3rem;
    }

    section {
        margin-bottom: 2.5rem;
        padding: 1rem 0;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.4rem;
    }

    p, ul li {
        font-size: 1.1rem;
    }

    .services-list {
        flex-direction: column;
        align-items: center;
    }

    .service-item {
        max-width: 400px;
    }

    .challenges.equipe-fundo {
        padding: 20px 15px;
    }

    .challenges.equipe-fundo ul li {
        font-size: 1.1rem;
    }

    .contact-info {
        flex-direction: column;
        align-items: center;
    }
    
    .contact-card {
        max-width: 100%;
    }

    .whatsapp-float {
        bottom: 15px !important;
        right: 15px !important;
        width: 55px !important;
        height: 55px !important;
    }

    .whatsapp-float img {
        width: 55px !important;
        height: 55px !important;
    }

    .whatsapp-balloon {
        right: 65px !important;
        font-size: 13px !important;
        padding: 10px 14px !important;
        max-width: 180px !important;
        white-space: normal !important;
        line-height: 1.3 !important;
    }

    .process-list {
        margin-left: 20px;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.6rem;
        letter-spacing: 0.08rem;
    }

    h2 {
        font-size: 1.8rem;
    }

    main {
        padding: 0 10px;
    }

    .challenges.equipe-fundo {
        padding: 20px 15px;
    }

    .whatsapp-balloon {
        right: 60px !important;
        font-size: 12px !important;
        padding: 8px 12px !important;
        max-width: 160px !important;
    }
}

/* ANIMAÇÕES E PERFORMANCE */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* DARK MODE SUPPORT */
@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
    }
}

/* HIGH CONTRAST MODE */
@media (prefers-contrast: high) {
    .service-item {
        border: 2px solid #ffffff;
    }
    
    .contact-card {
        border: 2px solid #ffffff;
    }
}

.whatsapp-float,
.whatsapp-float *,
.whatsapp-balloon,
.whatsapp-balloon * {
    box-sizing: border-box !important;
}

body .whatsapp-float {
    position: fixed !important;
    bottom: 20px !important;
    right: 20px !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
}

body .whatsapp-float:hover {
    transform: scale(1.1) !important;
}