
/* =========================================================
   SIGA | REDE SOCIAL PROFISSIONAL
   Identidade institucional ISUP
   Azul | Branco | Dourado
   ========================================================= */

:root {
    --siga-azul: #1456a0;
    --siga-azul-escuro: #103d70;
    --siga-azul-claro: #eaf3ff;
    --siga-dourado: #f5b51b;
    --siga-fundo: #f3f6fb;
    --siga-branco: #ffffff;
    --siga-texto: #202b3c;
    --siga-secundario: #748096;
    --siga-borda: #e4eaf2;
    --siga-verde: #16834a;
    --siga-vermelho: #d93025;
    --siga-sombra: 0 5px 22px rgba(24, 54, 95, .07);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--siga-fundo);
    color: var(--siga-texto);
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    line-height: 1.5;
}

button, input, textarea, select {
    font: inherit;
}

button {
    cursor: pointer;
}

img {
    max-width: 100%;
}

/* =========================================================
   CONTEÚDO PRINCIPAL
   ========================================================= */

.social-container {
    width: min(100% - 28px, 760px);
    margin: 22px auto 40px;
}

/* =========================================================
   CABEÇALHO
   ========================================================= */

.social-topo {
    position: sticky;
    top: 10px;
    z-index: 100;
    background: rgba(255,255,255,.96);
    border: 1px solid var(--siga-borda);
    border-radius: 17px;
    box-shadow: var(--siga-sombra);
    backdrop-filter: blur(12px);
}

.social-topo-interior {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 12px 17px;
}

.social-marca,
.social-perfil {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.social-marca {
    margin-right: auto;
}

.social-perfil {
    margin-left: auto;
}

.social-logo {
    display: grid;
    place-items: center;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    color: white;
    background: linear-gradient(140deg, #1681dc, #10427f);
    border: 3px solid var(--siga-dourado);
    border-radius: 14px;
    font-size: 23px;
    font-weight: 900;
    box-shadow: 0 4px 12px rgba(20,86,160,.18);
}

.social-marca strong {
    display: block;
    color: var(--siga-azul-escuro);
    font-size: 15px;
    letter-spacing: .3px;
}

.social-marca small {
    display: block;
    color: var(--siga-secundario);
    font-size: 11px;
}

.social-perfil > div {
    min-width: 0;
}

.social-perfil strong {
    display: block;
    max-width: 190px;
    overflow-wrap: anywhere;
    color: var(--siga-texto);
    font-size: 13px;
}

.social-perfil small {
    display: block;
    color: var(--siga-secundario);
    font-size: 11px;
}

/* =========================================================
   AVATARES
   ========================================================= */

.social-avatar-foto {
    display: block;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    object-fit: cover;
    border: 2px solid #e3edfa;
    border-radius: 50%;
    background: #edf3fb;
}

.social-autor img,
.social-comentario img {
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    object-fit: cover;
    border-radius: 50%;
    background: #edf3fb;
}

.social-comentario img {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
}

/* =========================================================
   APRESENTAÇÃO
   ========================================================= */

.social-apresentacao {
    position: relative;
    overflow: hidden;
    margin: 20px 0;
    padding: 28px;
    color: white;
    background:
        radial-gradient(circle at 90% 10%, rgba(64,205,225,.4), transparent 28%),
        linear-gradient(120deg, #103768, #1456a0 65%, #197fb0);
    border-radius: 19px;
    box-shadow: 0 12px 30px rgba(20,86,160,.15);
}

.social-apresentacao::after {
    content: "";
    position: absolute;
    right: -55px;
    bottom: -105px;
    width: 230px;
    height: 230px;
    border: 25px solid rgba(255,255,255,.08);
    border-radius: 50%;
    pointer-events: none;
}

.social-apresentacao h1 {
    position: relative;
    z-index: 1;
    margin: 0;
    color: white;
    font-size: clamp(23px, 4vw, 32px);
    line-height: 1.2;
}

.social-apresentacao p {
    position: relative;
    z-index: 1;
    margin: 9px 0 0;
    color: #e8f2ff;
}

/* =========================================================
   CARTÕES
   ========================================================= */

.social-card,
.social-publicacao,
.siga-comunidade-card,
.social-vazio {
    margin: 14px 0;
    background: var(--siga-branco);
    border: 1px solid var(--siga-borda);
    border-radius: 17px;
    box-shadow: var(--siga-sombra);
}

.social-card {
    padding: 20px;
}

.social-card h3,
.siga-comunidade-card h3 {
    margin: 0 0 13px;
    color: var(--siga-azul-escuro);
    font-size: 16px;
}

.social-card p {
    line-height: 1.7;
}

/* =========================================================
   PUBLICAÇÃO
   ========================================================= */

.social-card textarea,
.social-card input[type="text"],
.social-card select,
.social-form-comentario input {
    width: 100%;
    min-width: 0;
    padding: 12px 14px;
    color: var(--siga-texto);
    background: #f5f7fa;
    border: 1px solid var(--siga-borda);
    border-radius: 11px;
    outline: none;
    transition: .2s;
}

.social-card textarea {
    min-height: 115px;
    resize: vertical;
}

.social-card textarea:focus,
.social-card input:focus,
.social-card select:focus,
.social-form-comentario input:focus {
    background: white;
    border-color: var(--siga-azul);
    box-shadow: 0 0 0 3px rgba(20,86,160,.09);
}

.social-card label {
    color: var(--siga-azul-escuro);
    font-size: 12px;
}

.social-card input[type="file"] {
    display: block;
    width: 100%;
    margin-top: 7px;
    color: var(--siga-secundario);
    font-size: 12px;
}

.social-preview-imagens {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 12px;
}

.social-preview-imagens img {
    width: 85px;
    height: 85px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--siga-borda);
}

/* =========================================================
   BOTÕES E ACÇÕES
   ========================================================= */

.social-btn,
.social-accoes button,
.social-form-comentario button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 7px;
    min-height: 40px;
    padding: 9px 17px;
    color: white;
    background: var(--siga-azul);
    border: 1px solid var(--siga-azul);
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: background .2s, transform .15s, box-shadow .2s;
}

.social-btn:hover,
.social-accoes button:hover,
.social-form-comentario button:hover {
    background: var(--siga-azul-escuro);
    border-color: var(--siga-azul-escuro);
    box-shadow: 0 4px 12px rgba(20,86,160,.18);
    transform: translateY(-1px);
}

.social-btn:active,
.social-accoes button:active {
    transform: scale(.98);
}

.social-acoes {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 18px 0;
}

.social-acoes .social-btn {
    min-width: 125px;
}

.social-accoes {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    padding: 12px 0;
    border-top: 1px solid var(--siga-borda);
    border-bottom: 1px solid var(--siga-borda);
}

.social-accoes form {
    margin: 0;
}

.social-accoes button {
    min-height: 36px;
    padding: 7px 12px;
    color: var(--siga-azul);
    background: #edf4ff;
    border-color: transparent;
    font-size: 12px;
}

.social-accoes button:hover {
    color: white;
}

/* =========================================================
   CHAT-SIGA
   ========================================================= */

.siga-comunidade-card {
    padding: 19px;
    border-left: 4px solid var(--siga-azul);
}

.siga-comunidade-card p {
    margin: 0 0 14px;
    color: var(--siga-secundario);
    font-size: 13px;
}

.siga-chat-toggle {
    min-height: 39px;
    padding: 9px 16px;
    color: white;
    background: var(--siga-azul);
    border: 0;
    border-radius: 9px;
    font-weight: 700;
}

.siga-chat-toggle:hover {
    background: var(--siga-azul-escuro);
}

.siga-chat-frame {
    display: block;
    width: 100%;
    height: 570px;
    margin-top: 15px;
    border: 1px solid var(--siga-borda);
    border-radius: 12px;
    background: white;
}

/* =========================================================
   FEED
   ========================================================= */

.social-feed-titulo {
    margin: 26px 2px 13px;
    color: var(--siga-azul-escuro);
    font-size: 19px;
    font-weight: 800;
}

.social-publicacao {
    overflow: hidden;
    padding: 17px 19px 0;
}

.social-autor {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.social-autor > div {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.social-autor strong {
    color: var(--siga-texto);
    font-size: 13px;
    overflow-wrap: anywhere;
}

.social-autor small {
    margin-top: 3px;
    color: var(--siga-secundario);
    font-size: 11px;
}

.social-texto {
    padding: 15px 0;
    color: #263348;
    font-size: 14px;
    line-height: 1.8;
    overflow-wrap: anywhere;
}

/* =========================================================
   GALERIA
   ========================================================= */

.social-publicacao {
    min-width: 0;
}

.social-galeria {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
    width: 100%;
    margin: 10px 0 15px;
}

.social-galeria-item {
    width: 100%;
    max-height: 480px;
    overflow: hidden;
    background: #f1f3f6;
    border-radius: 12px;
}

.social-galeria-item img {
    display: block;
    width: 100%;
    max-height: 480px;
    object-fit: contain;
    cursor: zoom-in;
}

.social-galeria-item:has(img) {
    min-width: 0;
}

/* =========================================================
   COMENTÁRIOS
   ========================================================= */

.social-comentarios {
    padding: 15px 0 18px;
}

.social-comentarios h4 {
    margin: 0 0 12px;
    color: var(--siga-azul-escuro);
    font-size: 14px;
}

.social-comentario {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin: 9px 0;
    padding: 11px;
    background: #f3f6fa;
    border: 1px solid #edf0f5;
    border-radius: 12px;
}

.social-comentario-conteudo {
    min-width: 0;
}

.social-comentario strong {
    color: var(--siga-azul-escuro);
    font-size: 12px;
}

.social-comentario p {
    margin: 4px 0 0;
    color: #354155;
    font-size: 13px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.social-form-comentario {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 13px;
}

.social-form-comentario input {
    flex: 1;
    min-height: 41px;
    border-radius: 22px;
}

.social-form-comentario button {
    flex: 0 0 auto;
    min-height: 40px;
    border-radius: 22px;
}

/* =========================================================
   ALERTAS E ESTADO VAZIO
   ========================================================= */

.social-alerta {
    padding: 13px 15px;
    color: #842029;
    background: #fff0ef;
    border: 1px solid #ffd6d2;
    border-radius: 11px;
}

.social-vazio {
    padding: 35px 20px;
    text-align: center;
}

.social-vazio h3 {
    color: var(--siga-azul-escuro);
}

.social-vazio p {
    color: var(--siga-secundario);
}

/* =========================================================
   RODAPÉ
   ========================================================= */

.social-rodape {
    margin-top: 25px;
    padding: 20px;
    color: var(--siga-secundario);
    text-align: center;
    font-size: 12px;
}

/* =========================================================
   ACESSIBILIDADE
   ========================================================= */

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid var(--siga-azul);
    outline-offset: 3px;
}

/* =========================================================
   RESPONSIVIDADE
   ========================================================= */

@media (max-width: 600px) {

    .social-container {
        width: calc(100% - 14px);
        margin: 10px auto 25px;
    }

    .social-topo {
        top: 5px;
        border-radius: 13px;
    }

    .social-topo-interior {
        padding: 10px;
        gap: 8px;
    }

    .social-logo {
        flex-basis: 39px;
        width: 39px;
        height: 39px;
        font-size: 20px;
    }

    .social-marca strong {
        font-size: 13px;
    }

    .social-perfil {
        gap: 6px;
    }

    .social-perfil strong {
        max-width: 115px;
        font-size: 11px;
    }

    .social-perfil small {
        font-size: 10px;
    }

    .social-avatar-foto {
        flex-basis: 37px;
        width: 37px;
        height: 37px;
    }

    .social-apresentacao {
        margin: 13px 0;
        padding: 23px 19px;
        border-radius: 14px;
    }

    .social-apresentacao h1 {
        font-size: 23px;
    }

    .social-card {
        padding: 15px;
    }

    .social-publicacao {
        padding: 14px 13px 0;
        border-radius: 13px;
    }

    .social-autor img {
        flex-basis: 39px;
        width: 39px;
        height: 39px;
    }

    .social-texto {
        font-size: 13px;
    }

    .social-accoes {
        gap: 5px;
    }

    .social-accoes form {
        flex: 1 1 auto;
    }

    .social-accoes button {
        width: 100%;
        padding: 8px 7px;
        font-size: 11px;
    }

    .social-form-comentario {
        gap: 6px;
    }

    .social-form-comentario input {
        font-size: 12px;
    }

    .social-form-comentario button {
        padding: 8px 11px;
        font-size: 12px;
    }

    .siga-chat-frame {
        height: 500px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
