/* styles.css */

/* Estilos gerais do corpo */
body {
    font-family: 'Roboto',sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
}


.container {
    width: 100%;
    max-width: 500px;
    margin: 50px 85px;
    text-align: left;
}

h3 {
    margin-top: 20px;
    font-size: 18px;
}

section {
    display: flex;
    unicode-bidi: isolate;
    display: flex;
    justify-content: space-between;
    align-content: space-around;
    flex-wrap: nowrap;
    flex-direction: row;
    align-items: stretch;
    margin-bottom: 50px;
    padding: 1px 65px;
}

section a {
    color: #0059ff;
    cursor: pointer;
    text-decoration: underline;
    text-decoration: none;
}

#name-or-registry {
    width: 85%;
    padding: 10px;
    margin-top: -7px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 12px;
    background: #f4f4f4;
    color: #575757;
}

#recaptcha-input {
    width: 20%;
    padding: 10px;
    margin-top: -20px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 12px;
    background: #f4f4f4;
    color: #575757;
}

.Txt-recaptcha {
    display: flex;
}

select {
    width: 90%;
    padding: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    border: 0 solid;
    border-radius: 5px;
    font-size: 16px;
    background: #f4f4f4;
}

#recaptcha-text {
    display: inline-block;
    padding: 10px;
    margin-left: -10px;
    font-family: 'Roboto', sans-serif;
    font-size: 15px;
    color: #444;
}

.button {
    width: 90%;
    padding: 10px;
    font-weight: 700;
    border: none;
    border-radius: 4px;
    background-color: #ffba52;
    font-size: 14px;
    color: #333;
    cursor: not-allowed;
}

.button:enabled {
    background-color: #fd7e14;
    cursor: pointer;
}

.button:enabled:hover {
    background-color: #fd7e14;
}

#botao-txt {
    font-size: 13px;
    margin-top: -15px;
    display: block;
    margin-block-start: -15px;
    margin-block-end: 1em;
    margin-inline-start: 0px;
    margin-inline-end: 0px;
    unicode-bidi: isolate;
}

/* ----------------------------------------------------------------------------------------------- */

/* Cabeçalho principal */
.main-header {
    background-color: #0060af;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
    position: relative;
}

/* styles.css */

/* Faixa da Logo */
.logo-header {
    background-color: #c3e0ed; /* Cor de fundo da faixa */
    padding: 14px 150px; /* Espaçamento interno vertical e horizontal */
    text-align: left; /* Alinha a logo à esquerda */
}

.logo-container {
    display: inline-block; /* Para garantir que o contêiner da logo ocupe apenas o espaço necessário */
}

.logo {
    width: 230px; /* Tamanho da logo */
    max-width: 80%; /* Responsivo para não ultrapassar o contêiner */
}

.content {
    padding: 20px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.header-text {
    max-width: 60%;
}

.header-text h1 {
    font-weight: 700;
    font-size: 29PX;
    margin: 10px 0;
    margin-bottom: 2.5rem;
}

.header-text p {
    color: #676767;
    font-size: 15px;
    margin: 5px 0;
}

/* Estilo da caixa de DIPLOMA DIGITAL */

.consulta-container {
    max-width: 270px;
    min-width: 0px;
    height: 10.000rem;
    background: linear-gradient(to right, #3117D6, #2511A4);
    padding: 5px 10px 10px 12px;
    border-radius: 7px;
    flex-direction: column;
    display: flex;
    margin-left: auto;
    line-height: 38px;
}

.consulta-diploma {
    display: flex;
    margin-bottom: 1.75rem;
    align-items: center;
    justify-content: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: space-around;
}

.consulta-diploma img {
    width: 80px;
    margin-top: -10px;
    height: auto;
    margin-right: 0px;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-content: space-between;
    justify-content: flex-start;
    align-items: stretch;
}

.consulta-diploma h2 {
    font-size: 25px;
    margin-top: -30px;
    margin: 0;
    color: #ffffff;
    display: block;
    margin-block-start: 20px;
    margin-block-end: 20px;
    margin-inline-start: 20px;
    margin-inline-end: 0px;
    unicode-bidi: isolate;
}

.consulta-input-container {
    display: flex;
    align-items: center;
    border-radius: 7px;
    overflow: hidden;
    background-color: #ffffff;
    margin: 12px;
    box-sizing: border-box;
    margin-top: 0px;
}

#consulta-input {
  border: none;
  outline: none;
  width: 315px;
  background: #FFF;
  /*padding: 5px 89px;*/
  font-size: 12px;
  line-height: 20px;
  color: #4e4e4e;
}

#consulta-button {
    border-radius: .313rem;
    border: none;
    outline: none;
    width: 17%;
    background: #FFF;
    padding: .5rem 1rem;
    font-size: .75rem;
    line-height: .875rem;
    color: #4e4e4e;
}

#consulta-button:hover {
    background-color: #ccb4ff;
}


.consulta-form {
    display: flex;
    align-items: center;
}

.consulta-form input {
    padding: 10px;
    width: 200px;
    margin-right: 10px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
}

.consulta-form button {
    padding: 10px;
    background-color: #ffffff;
    color: #1e3a8a;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 18px;
}


.top-bar {
    background-color: #d7e9f1; /* Cor de fundo da faixa */
    padding: 30px 150px; /* Espaçamento interno vertical e horizontal */
    display: flex; /* Exibe logo e caixa de consulta lado a lado */
    justify-content: space-between; /* Alinha logo à esquerda e caixa à direita */
    /* align-items: ; /* Centraliza verticalmente os itens na faixa */
}


/* Estilos para a Seção de Pesquisa */
.search-section {
    padding: 30px 50px;
    background-color: #f9f9f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.search-form {
        display: block;
        width: 100%;
        padding: .375rem 2.25rem .375rem .75rem;
        -moz-padding-start: calc(.75rem - 3px);
        font-size: 1rem;
        font-weight: 400;
        line-height: 1.5;
        color: #292121;
        background-repeat: no-repeat;
        background-position: right .75rem center;
        background-size: 16px 12px;
        border-radius: .25rem;
        transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
    }
 

.search-form h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
}

.search-form select,
.search-form input {
    width: 105%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    background: #ecedee;
}

.search-form input#name-or-registry {
    margin-top: 15px;
    
}

#search-diploma {
    width: 100%;
    padding: 12px;
    background-color: #FFC107;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    color: #333;
    cursor: pointer;
}

#search-diploma:hover {
    background-color: #FFB300;
}

.institution-image {
    text-align: right;
    flex-shrink: 0;
    display: flex;
    padding: 80px;
}

.institution-image img {
    max-width: 100%;
    height: auto;
}


.link-to-top {
    display: block;
    margin-top: 10px;
    font-size: 14px;
    color: #0060af; /* Cor do texto */
    text-decoration: underline; /* Sublinhado para parecer um link */
}

.link-to-top:hover {
    color: #31ff00; /* Cor do texto ao passar o mouse */
    text-decoration: none; /* Remove o sublinhado ao passar o mouse */
}


html {
    scroll-behavior: smooth;
}



/* ---------------------------------- Seção de Informações sobre o código -------------------------------- */
.code-info {
    background-color: #FFFFFF;
    padding: 40px 20px;
    /* text-align:; */
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-content: space-around;
    justify-content: center;
    background: #f4f4f4;
}

.code-info h2 {
    font-size: 30px;
    margin-bottom: -10px;
    font-weight: bold;
    position: relative;
    display: inline-block;
    padding: 1px 130px;
}

.code-info h2::before {
    content: "";
    position: absolute;
    top: -10px; /* Ajuste para posicionar acima do texto */
    left: 10;
    width: 60px; /* Largura da linha amarela */
    height: 4px; /* Altura da linha amarela */
    background-color: #ffcc00; /* Cor da linha amarela */
}

.code-images {
    display: flex;
    justify-content: center;
    gap: -10px;
    margin-top: 10px;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
}

.image-container {
    text-align: center;
    margin: 0 20px;
}

.image-container h3 {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: start;
}

.image-container img {
    max-width: 485px;
    padding: 1px;
    background-color: #f9f9f9;
}




/*------------------------------ Seção de Dúvidas Frequentes ----------------------------------------- */


.faq-container {
    max-width: 86%;
    margin: 0 auto;
    padding: 10px;
}

.faq-container h2 {
    font-size: 30px;
    margin-bottom: 60px;
    font-weight: bold;
    position: relative;
    display: inline-block;
    padding: 0px 0px;
}

.faq-container h2::before {
    content: "";
    position: absolute;
    top: -10px; /* Ajuste para posicionar acima do texto */
    left: 10;
    width: 60px; /* Largura da linha amarela */
    height: 4px; /* Altura da linha amarela */
    background-color: #ffcc00; /* Cor da linha amarela */
}

.faq-item {
    border: 1px solid #0060af;
    border-radius: 5px;
    margin-bottom: 10px;
    overflow: hidden; /* Esconde o conteúdo que está fora da altura definida */
    transition: height 0.3s ease; /* Transição suave de altura */
}

.faq-question {
    background-color: #f4f4f4;
    padding: 15px;
    cursor: pointer;
    position: relative;
    font-weight: bold;
    border-radius: 5px;
    box-sizing: border-box;
}

.faq-question .chevron {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 15px;
    background-color: #fff;
    border-top: 1px solid #0060af;
    border-radius: 5px;
    transition: max-height 0.3s ease-out; /* Transição suave de altura */
}

.faq-item.active .faq-answer {
    max-height: 500px; /* Define uma altura máxima para o conteúdo expandido */
    padding: 15px;
    border-radius: 5px;
}

.faq-item .faq-question .chevron svg {
    transition: transform 0.3s ease;
    width: 16px;
    height: 16px;
}

.faq-item.active .faq-question .chevron svg {
    transform: rotate(180deg); /* Seta apontando para cima quando aberto */
}




/* ----------------------------------Rodapé principal---------------------------------- */


.footer {
    background-color: #297ca1; /* cor de fundo */
    color: #ffffff; /* cor do texto */
    padding: 20px;
    font-family: 'Roboto',sans-serif;
}

.footer-top {
    display: flex;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #004080;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: center;
    justify-content: space-between;
    margin-right: 80px;
    margin-left: 77px;
}

.footer-left .logo {
    max-height: 50px;
}

.footer-right .contact {
    display: flex;
    gap: 30px;
}

.footer-right .contact span {
    display: flex;
    align-items: center;
}

.footer-right .contact i {
    margin-right: 10px;
}

.phone-icon {
    background-image: url('img/phone-icon.svg');
    width: 32px;
    height: 32px;
    display: inline-block;
}

.whatsapp-icon {
    background-image: url('img/whatsapp-icon.svg');
    width: 24px;
    height: 24px;
    display: inline-block;
    vertical-align: middle;
}

a:-webkit-any-link {
    color: white;
    cursor: pointer;
    text-decoration: none;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    margin-right: 70px;
    margin-left: 80px;
}

.footer-links a {
    color: #ffffff;
    text-decoration: none;
    margin-right: 20px;
}

.footer-links a:hover {
    text-decoration: underline;
}

/* Estilo da área do QR Code e-MEC */
.emec-container {
    display: flex;
    align-items: center;
    padding: 15px;
    border-radius: 10px;
}

.emec-content p {
    margin: 0;
    font-size: 14px;
    color: #ffffff;
}

.emec-qr {
    margin-left: 15px;
}

.emec-qr img {
    max-width: 260px;
    border-radius: 5px; /* Borda arredondada ao redor do QR Code */
}

.footer-copy {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #004080;
    margin-top: 20px;
}

.footer-copy p {
    margin: 0;
    font-size: 14px;
}

@media (max-width: 768px) {
    .footer-top,
    .footer-bottom {
        flex-direction: column;
        align-items: center;
    }

    .footer-right {
        margin-top: 20px;
    }

    .footer-links {
        text-align: center;
        margin-bottom: 15px;
    }

    .emec-container {
        margin-top: 20px;
        flex-direction: column;
        align-items: center;
    }

    .emec-content p {
        text-align: center;
    }

    .footer-copy {
        padding-top: 15px;
        margin-top: 15px;
    }
}



/* Carregamento da consulta ------------------------------------------------------------------------------*/



.hidden {
    display: none;
}

.loading-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.image-container-carregamento {
    position: relative;
    width: 90px; /* Ajuste o tamanho conforme necessário */
    height: 90px; /* Ajuste o tamanho conforme necessário */
}

.loading-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.loading-effect {
    position: absolute;
    top: 4px;
    left: 3px;
    width: 90%;
    height: 90%;
    border: 8px solid transparent;
    box-sizing: border-box;
    animation: glow-border 2s linear infinite;
    transform: rotate(135deg);
}

@keyframes glow-border {
    0% {
        border-top-color: rgba(255, 255, 255, 1);
        border-right-color: transparent;
        border-bottom-color: transparent;
        border-left-color: transparent;
    }
    25% {
        border-top-color: transparent;
        border-right-color: rgba(255, 255, 255, 1);
        border-bottom-color: transparent;
        border-left-color: transparent;
    }
    50% {
        border-top-color: transparent;
        border-right-color: transparent;
        border-bottom-color: rgba(255, 255, 255, 1);
        border-left-color: transparent;
    }
    75% {
        border-top-color: transparent;
        border-right-color: transparent;
        border-bottom-color: transparent;
        border-left-color: rgba(255, 255, 255, 1);
    }
    100% {
        border-top-color: rgba(255, 255, 255, 1);
        border-right-color: transparent;
        border-bottom-color: transparent;
        border-left-color: transparent;
    }
}

.loading-container p {
    color: white;
    font-size: 22px;
    margin-top: 15px;
}



/* Alerta Personalizado ------------------------------------------------------------------------------------*/
/* Notificação ajustável para qualquer tela */
.custom-alert {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(233, 233, 233, 0.85);
    color: #000000;
    padding: 15px; /* 🔥 Ajuste para telas pequenas */
    border-radius: 10px;
    text-align: center;
    width: 90%;
    max-width: 400px;
    min-width: 280px; /* 🔥 Garante que não fique muito pequeno */
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    animation: fadeIn 0.5s ease-in-out;
}

/* Barra de progresso */
.progress-bar {
    width: 100%;
    height: 5px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-bar-fill {
    width: 100%;
    height: 100%;
    background: #ffffff;
    transition: width linear;
}

/* Botão de fechar */
.custom-alert button {
    margin-top: 10px;
    padding: 8px 15px;
    background: #3117d6;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.custom-alert button:hover {
    background: #4023ff;
}

/* Animações */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translate(-50%, -55%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
    to {
        opacity: 0;
        transform: translate(-50%, -55%);
    }
}

/* 🔥 Ajuste para telas menores */
@media screen and (max-width: 400px) {
    .custom-alert {
        width: 85%; /* 🔥 Reduz um pouco para não tocar as laterais */
        min-width: 250px;
        padding: 12px;
    }

    .custom-alert button {
        padding: 7px 12px;
        font-size: 14px;
    }
}


/* Carregamento -----------------------------------------------------------------------------------------------------------------*/
/* 🔥 Garante que o carregamento NÃO aparece ao carregar a página */
#loading-overlay {
    display: none; /* 🔥 Removemos o `!important` para que o JavaScript possa ativar o carregamento */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 9999;
    color: white;
    font-size: 18px;
    text-align: center;
}

/* Loader com efeito de bolhas */
.dot-ripple {
    position: relative;
    width: 30px;
    height: 30px;
    margin-bottom: 10px; /* 🔥 Ajusta a distância entre as bolhas e o texto */
}

/* Criando as três bolinhas */
.dot-ripple::before,
.dot-ripple::after,
.dot-ripple div {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.9);
    transform: translate(-50%, -50%);
    animation: dotRipple 1s infinite ease-out;
}

.dot-ripple::after {
    animation-delay: 0.3s;
    background-color: rgba(255, 255, 255, 0.6);
}

.dot-ripple div {
    animation-delay: 0.6s;
    background-color: rgba(255, 255, 255, 0.3);
}

/* Animação das bolinhas crescendo e desaparecendo */
@keyframes dotRipple {
    0% {
        transform: translate(-50%, -50%) scale(0.2);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}
