/* Vereador Profile Styles - Portal de Transparência */
/* Paleta govbr: --govbr-blue: #1351b4 */

.vereador-container {
    background-color: #f8f9fa;
    min-height: 100vh;
}

/* Compact Header Section */
.vereador-header-section {
    background: linear-gradient(135deg, #1351b4 0%, #0c3d85 100%);
    color: white;
    padding: 30px 0;
    position: relative;
    overflow: hidden;
}

.vereador-header-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.vereador-profile-border {
    box-shadow: var(--box-shadow);
    padding: 2rem;
    margin-bottom: 2rem;
    margin-top: 1rem;
    border-left: 4px solid var(--primary-color);
}

.vereador-profile-image {
    position: relative;
    z-index: 2;
}

/* ====== Container da imagem ====== */
.vereador-profile-image {
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 8px;
    width: 180px;
    height: 180px;
    margin-right: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.card-post__image {
    position: relative;
    min-height: 10.3125rem;
    border-top-left-radius: .625rem;
    border-top-right-radius: .625rem;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* ====== Imagem ====== */
.vereador-profile-image img {
    width: 100%;
    height: 100%;
    /*object-fit: cover;
     mantém proporção sem distorcer */
    object-position: center;
    /* centraliza o rosto */
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.vereador-profile-image img:hover {
    transform: scale(1.05);
}

/* ====== Responsividade ====== */
@media (max-width: 767.98px) {
    .vereador-profile-image {
        width: 120px;
        height: 120px;
        margin: 0 auto 15px auto;
        border-radius: 50%;
    }

    .vereador-profile-image img {
        border-radius: 50%;
        object-fit: cover;
    }
}

.vereador-profile-image img:hover {
    transform: scale(1.05);
}

.vereador-profile-info {
    position: relative;
    z-index: 2;
}

.vereador-name {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.vereador-title {
    font-size: 1rem;
    margin-bottom: 12px;
    opacity: 0.9;
    font-weight: 300;
}

.vereador-description {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0;
    opacity: 0.95;
}

.vereador-contact-quick {
    position: relative;
    z-index: 2;
}

.vereador-contact-quick .contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    font-size: 0.85rem;
}

.vereador-contact-quick .contact-item i {
    margin-right: 8px;
    width: 16px;
    text-align: center;
}

.vereador-social-links {
    display: flex;
    gap: 8px;
    margin-top: 15px;
}

.vereador-btn-social {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    font-size: 0.8rem;
}

.vereador-btn-social:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    transform: translateY(-2px);
}

/* Compact Stats Section */
.vereador-stats-section {
    padding: 30px 0;
    background: white;
    margin-top: -15px;
    position: relative;
    z-index: 3;
    border-radius: 15px 15px 0 0;
    box-shadow: 0 -3px 15px rgba(0, 0, 0, 0.1);
}

.vereador-stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 123, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.vereador-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #007bff, #28a745);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.vereador-stat-card:hover::before {
    transform: scaleX(1);
}

.vereador-stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.stat-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.stat-icon i {
    font-size: 1.8rem;
    color: #1351b4;
}

.stat-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.stat-info p {
    color: #6c757d;
    font-weight: 500;
    margin: 0;
    font-size: 0.85rem;
}

/* Main Content */
.vereador-main-content {
    padding: 30px 0;
}

.vereador-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

.vereador-card:hover {
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.vereador-card-header {
    background: linear-gradient(135deg, #1351b4 0%, #0c3d85 100%);
    color: #fff;
    padding: 1rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    border-top-left-radius: 0.5rem;
    border-top-right-radius: 0.5rem;
    font-weight: 500;
    font-size: 1.1rem;
    box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.1);
}



.vereador-card-header h4 {
    margin: 0;
    color: #fff;
    font-weight: 600;
    font-size: 1.1rem;
}

.vereador-card-body {
    padding: 20px;
}

/* Map Search Styles */
.map-search-container {
    position: relative;
}

#addressSearch {
    border-radius: 0.375rem 0 0 0.375rem;
    border-right: none;
    font-size: 0.9rem;
}

#addressSearch:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    border-color: #007bff;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #dee2e6;
    border-top: none;
    border-radius: 0 0 0.375rem 0.375rem;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: none;
}

.suggestion-item {
    padding: 12px 15px;
    cursor: pointer;
    border-bottom: 1px solid #f1f3f4;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.suggestion-item:hover {
    background-color: #f8f9fa;
    border-left: 3px solid #007bff;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-icon {
    color: #6c757d;
    font-size: 0.9rem;
    width: 16px;
    text-align: center;
}

.suggestion-content {
    flex: 1;
}

.suggestion-title {
    font-weight: 600;
    color: #2c3e50;
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.suggestion-subtitle {
    color: #6c757d;
    font-size: 0.8rem;
}

.suggestion-status {
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 500;
}

.status-concluida {
    background-color: #e3f2fd;
    color: #1976d2;
}

.status-andamento {
    background-color: #fff3e0;
    color: #f57c00;
}

.status-aprovado {
    background-color: #e8f5e8;
    color: #388e3c;
}

/* Map Styles */
#atuacao-map {
    border-radius: 0;
}

.map-legend {
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

.legend-items {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.legend-item {
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Project Cards */
.project-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #007bff;
    transition: all 0.3s ease;
}

.project-card:hover {
    background: #e9ecef;
    transform: translateX(3px);
}

.project-card h6 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

/* Activity Timeline */
.activity-timeline {
    position: relative;
}

.timeline-item {
    display: flex;
    margin-bottom: 20px;
    align-items: flex-start;
}

.timeline-date {
    background: #007bff;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    min-width: 45px;
    text-align: center;
    margin-right: 15px;
    margin-top: 2px;
}

.timeline-content h6 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 0.95rem;
}

/* Commission Items */
.commission-item {
    padding: 12px 0;
    border-bottom: 1px solid #f1f3f4;
}

.commission-item:last-child {
    border-bottom: none;
}

/* Document Links */
.document-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.document-link {
    display: flex;
    align-items: center;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
    text-decoration: none;
    color: #2c3e50;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.document-link:hover {
    background: #e9ecef;
    color: #007bff;
    text-decoration: none;
    transform: translateX(3px);
}

/* Responsive Design */
@media (max-width: 768px) {
    .vereador-name {
        font-size: 1.5rem;
    }

    .vereador-profile-image img {
        width: 100px;
        height: 100px;
    }

    .vereador-stats-section {
        padding: 20px 0;
    }

    .vereador-stat-card {
        padding: 15px;
        margin-bottom: 15px;
    }

    .stat-content {
        flex-direction: column;
        gap: 10px;
    }

    .vereador-header-section {
        padding: 20px 0;
        text-align: center;
    }

    .vereador-contact-quick {
        margin-top: 20px;
    }

    .legend-items {
        justify-content: center;
    }

    #atuacao-map {
        height: 300px !important;
    }

    .search-suggestions {
        max-height: 200px;
    }

    .suggestion-item {
        padding: 10px 12px;
    }
}

@media (max-width: 576px) {

    .vereador-card-body,
    .vereador-card-header {
        padding: 15px;
    }

    .stat-info h3 {
        font-size: 1.5rem;
    }

    .timeline-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .timeline-date {
        margin-bottom: 8px;
        margin-right: 0;
    }

    .map-search-container {
        padding: 15px !important;
    }
}

/* Animation Classes */
.vereador-card {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.vereador-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Custom Leaflet Popup Styles */
.leaflet-popup-content-wrapper {
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.leaflet-popup-content {
    margin: 12px 16px;
    font-size: 0.9rem;
}

.popup-title {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.popup-status {
    font-size: 0.8rem;
    margin-bottom: 8px;
}

.popup-description {
    color: #6c757d;
    font-size: 0.85rem;
    line-height: 1.4;
}

.vereador-btn-social {
    width: 36px;
    height: 36px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin: 0 6px;
    border-radius: 50%;
    background-color: #f1f1f1;
    color: #444;
    font-size: 18px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.08);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeSlideUp 0.6s forwards;
}

.social-icons a:nth-child(1) {
    animation-delay: 0.1s;
}

.social-icons a:nth-child(2) {
    animation-delay: 0.2s;
}

.social-icons a:nth-child(3) {
    animation-delay: 0.3s;
}

.social-icons a:nth-child(4) {
    animation-delay: 0.4s;
}

@keyframes fadeSlideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.social-icons a:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    color: #fff;
}

.social-icons a.facebook:hover {
    background-color: #3b5998;
}

.social-icons a.twitter:hover {
    background-color: #1da1f2;
}

.social-icons a.instagram:hover {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
}

.social-icons a.whatsapp:hover {
    background-color: #25d366;
}

.social-icons a.youtube:hover {
    background-color: #ff0000;
}

/* ===========================================
   TIPO DE PROPOSIÇÃO – Cards compactos
   (migrado do style inline de parlamentar.asp)
=========================================== */
.tipo-card {
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    padding: 10px 0;
    text-align: center;
}

.tipo-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.tipo-card .badge {
    font-size: 1rem;
    padding: 6px 12px;
}

/* ===========================================
   TABS DE ESTATÍSTICAS DO MANDATO
   (migrado + atualizado para govbr)
=========================================== */
.nav-pills .nav-link {
    border-radius: 20px;
    color: #555;
    font-weight: 600;
    padding: 8px 20px;
    transition: all 0.3s ease;
}

.nav-pills .nav-link.active,
.nav-pills .nav-link[aria-selected="true"] {
    background-color: #1351b4;
    color: #fff !important;
    box-shadow: 0 0 10px rgba(19, 81, 180, 0.3);
}

.nav-pills .nav-link:focus-visible {
    outline: 3px solid #ffcd07;
    outline-offset: 2px;
}

/* ===========================================
   PAGE HEADER – Override para perfil
=========================================== */
.parlamentar-content .page-header {
    padding: 0;
    margin-bottom: 2rem;
    margin-top: 1rem;
    border-left: 4px solid #1351b4;
}

/* ===========================================
   LINKS EXTERNOS – Indicador de nova aba
   (acessibilidade: informa usuário)
=========================================== */
.document-link[target="_blank"]::after,
.project-card a[target="_blank"]::after {
    content: " \f35d";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    font-size: 0.7em;
    vertical-align: super;
    margin-left: 3px;
    opacity: 0.6;
}

/* ===========================================
   RESPONSIVO – Cards de Mandato
   (migrado do style inline de parlamentar.asp)
=========================================== */
@media (max-width: 767.98px) {

    #cardsMandato .col-lg-3,
    #cardsMandato .col-md-4,
    #cardsMandato .col-sm-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    .tipo-card .badge {
        font-size: 0.9rem;
    }

    .tipo-card i {
        font-size: 24px !important;
    }

    .nav-pills {
        flex-wrap: wrap;
    }

    .nav-pills .nav-link {
        margin-bottom: 5px;
    }
}

@media (max-width: 400px) {

    #cardsMandato .col-lg-3,
    #cardsMandato .col-md-4,
    #cardsMandato .col-sm-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

@media (min-width: 768px) and (max-width: 991.98px) {
    .stat-icon {
        font-size: 30px;
    }

    .tipo-card .badge {
        font-size: 0.95rem;
    }
}