/**
 * CidadeTur BR - Estilos do Assistente de Serviços e Cidade
 */

/* ============================================
   ASSISTENTE DE SERVIÇOS
   ============================================ */

.assistente-section {
    margin-top: 20px;
    margin-bottom: 10px;
    border-radius: 10px;
    background-color: #B0C3D7;
}

.assistente-header {
    background-color: #B0C3D7;
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 10px 10px 0 0;
}

.assistente-title-text {
    color: #FFFFFF;
    font-size: 15px;
    font-weight: normal;
}

.assistente-dropdown-btn {
    background-color: #92ADC9;
    border: none;
    color: #FFFFFF;
    font-size: 16px;
    cursor: pointer;
    padding: 4px 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s;
}

.assistente-dropdown-btn:hover {
    opacity: 0.8;
}

/* Tooltips dos controles de navegação do ecossistema */
.ui-tooltip-trigger {
    position: relative;
    overflow: visible !important;
    z-index: 30;
}

.ui-tooltip-trigger::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 50%;
    top: calc(100% + 8px);
    transform: translateX(-50%) translateY(0);
    background: #2f4358;
    color: #ffffff;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 600;
    white-space: nowrap;
    border-radius: 6px;
    padding: 6px 8px;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.22);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.06s linear, visibility 0.06s linear;
    z-index: 10020;
}

.ui-tooltip-trigger::before {
    content: "";
    position: absolute;
    left: 50%;
    top: calc(100% + 2px);
    transform: translateX(-50%) translateY(0);
    border-width: 0 5px 6px 5px;
    border-style: solid;
    border-color: transparent transparent #2f4358 transparent;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.06s linear, visibility 0.06s linear;
    z-index: 10020;
}

.ui-tooltip-trigger:hover::after,
.ui-tooltip-trigger:hover::before,
.ui-tooltip-trigger:focus-visible::after,
.ui-tooltip-trigger:focus-visible::before {
    opacity: 1;
    visibility: visible;
}

.ui-tooltip-edge-right::after {
    left: auto;
    right: 0;
    transform: none;
}

.ui-tooltip-edge-right::before {
    left: auto;
    right: 12px;
    transform: none;
}

.assistente-content {
    background-color: #B0C3D7;
}

.assistente-placeholder {
    height: 250px;
    background-color: #BEBEBE;
    margin: 0 15px;
    border-radius: 20px;
    border: none;
    width: calc(100% - 30px);
    display: block;
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
}

.assistente-placeholder-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ============================================
   HEADER DA CIDADE (Nome + UF)
   ============================================ */

.city-info-header {
    padding: 15px 20px 10px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.city-info-header .city-name {
    color: var(--text-black);
    font-size: 20px;
    font-weight: bold;
    margin: 0 0 2px 0;
    padding: 0;
    line-height: 1.2;
}

.city-info-header .city-uf {
    color: var(--text-black);
    font-size: 14px;
    font-weight: normal;
    display: block;
}

/* ============================================
   ÁREA DE INFORMAÇÕES DA CIDADE
   ============================================ */

.city-info-section {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.city-info-left {
    flex-shrink: 0;
}

.city-logo-small {
    width: 88px;
    height: 88px;
    background-color: #D9D9D9;
    border-radius: 10px;
    border: 1px solid #AFAFAF;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.city-logo-small .logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
    max-width: none;
    max-height: none;
    transform: none;
}

.city-info-center {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.city-links {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.city-link {
    color: var(--text-body);
    text-decoration: none;
    font-size: 14px;
    line-height: 1.4;
    transition: text-decoration 0.3s;
}

.city-link:hover {
    text-decoration: underline;
}

.city-link.active {
    text-decoration: underline;
}

/* ============================================
   BOTÕES DE NAVEGAÇÃO DA CIDADE
   ============================================ */

.city-nav-buttons {
    display: flex;
    gap: 8px;
    margin: 10px 0 10px 0;
    justify-content: flex-end;
}

.city-nav-btn {
    width: 35px;
    height: 25px;
    background-color: #CBD3D7;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    color: #ffffff;
    font-size: 14px;
    padding: 0;
}

.city-nav-btn:hover {
    background-color: rgba(224, 224, 224, 0.8);
}

.city-nav-buttons .assistente-dropdown-btn.city-nav-btn {
    background-color: #CBD3D7;
    color: #FFFFFF;
}

.city-nav-buttons .assistente-dropdown-btn.city-nav-btn:hover {
    background-color: rgba(224, 224, 224, 0.8);
    opacity: 1;
}

/* ============================================
   EXPANDIR/RECOLHER TODOS
   ============================================ */

.expand-toggle-section {
    padding: 15px 20px;
    text-align: left;
}

.expand-toggle-btn {
    background-color: transparent;
    border: none;
    color: #FFFFFF;
    font-size: 13px;
    cursor: pointer;
    padding: 0;
    transition: opacity 0.3s;
    text-decoration: underline;
}

.expand-toggle-btn:hover {
    opacity: 0.8;
}

.expand-toggle-btn:first-child::after {
    content: " / ";
    text-decoration: none;
    margin: 0 5px;
}

/* ============================================
   SEÇÕES DA CIDADE
   ============================================ */

.city-sections-list {
    margin: 0 15px 15px 15px;
}

.city-sections-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.city-section-item {
    background-color: #FFFFFF;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.city-section-title {
    background-color: #FFFFFF;
    color: #5A5A5A;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 13px;
    padding: 15px 18px;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0;
    transition: background-color 0.3s;
}

.city-section-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-right: 10px;
}

.city-section-title .city-section-title-text {
    flex: 1;
    text-align: left;
    margin-right: 10px;
}

.city-section-title:hover {
    background-color: #D0DBE8;
}

.city-section-title .toggle-icon {
    flex-shrink: 0;
    color: #5A5A5A;
    font-size: 16px;
    transition: transform 0.3s;
}

.city-section-title .toggle-icon.rotated {
    transform: rotate(-180deg);
}

.city-section-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background-color: #F9F9F9;
}

.city-section-content.active {
    max-height: none;
    padding: 15px 20px;
    border-top: 1px solid #ccc;
    overflow: visible;
    padding-right: 20px;
}

.city-section-content.active::-webkit-scrollbar {
    width: 8px;
}

.city-section-content.active::-webkit-scrollbar-track {
    background: #e7ebef;
    border-radius: 8px;
}

.city-section-content.active::-webkit-scrollbar-thumb {
    background: #9fb0c0;
    border-radius: 8px;
}

/* ============================================
   CONTEÚDO DAS NOTÍCIAS DENTRO DAS SEÇÕES
   ============================================ */

.city-news-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.city-news-item {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 15px;
    padding: 15px 0;
    width: 100%;
}

.city-news-image {
    flex-shrink: 0;
}

.city-news-image-btn,
.city-place-image-btn {
    border: none;
    background: transparent;
    padding: 0;
    cursor: pointer;
    display: block;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
}

.city-news-placeholder {
    width: 85px;
    height: 85px;
    background-color: #BEBEBE;
}

.city-news-image-btn img {
    width: 85px;
    height: auto;
    object-fit: contain;
    object-position: top center;
    display: block;
}

.city-place-image-btn img {
    width: 85px;
    height: 85px;
    object-fit: cover;
    display: block;
}

.city-news-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.city-news-title {
    color: #000000;
    font-size: 14px;
    font-weight: normal;
    margin: 0;
    padding: 0;
    line-height: 1.4;
    word-wrap: break-word;
    transition: color 0.2s;
}

.city-news-item:hover .city-news-title {
    color: #FF6600;
}

.city-news-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.city-news-details p {
    color: #666666;
    font-size: 10px;
    margin: 0;
    padding: 0;
    line-height: 1.4;
}

.city-news-details .news-details-label {
    color: #666666;
}

.city-news-details .news-details-link {
    color: #003399;
    text-decoration: none;
}

.city-news-details .news-details-link:hover {
    text-decoration: underline;
}

.city-news-details .news-source-unavailable {
    color: #7a7a7a;
}

.city-news-separator {
    width: 100%;
    height: 1px;
    background-color: #E0E0E0;
    margin: 0;
}

.city-news-footer {
    text-align: right;
    padding-top: 15px;
    margin-top: 10px;
}

.city-list-all-btn {
    background-color: transparent;
    border: none;
    color: #FF8C00;
    font-size: 14px;
    font-weight: normal;
    cursor: pointer;
    padding: 0;
    text-decoration: none;
    transition: opacity 0.3s;
}

.city-list-all-btn:hover {
    opacity: 0.8;
}

.city-section-text {
    color: #666666;
    font-size: 14px;
    line-height: 1.6;
    padding: 10px 0;
}

/* Balão visual do conteúdo textual (padronizado para todas as páginas) */
.index5-editor-text {
    background: #ffffff;
    border: 1px solid #d6dfe8;
    border-radius: 8px;
    padding: 14px 16px;
    color: #3a4b5c;
    line-height: 1.65;
}

.index5-editor-text > .city-section-scrollable > *:first-child {
    margin-top: 0;
}

.index5-editor-text > .city-section-scrollable > *:last-child {
    margin-bottom: 0;
}

.index5-editor-text p {
    margin: 0 0 12px 0;
    font-size: 13px;
}

.index5-editor-text h1,
.index5-editor-text h2,
.index5-editor-text h3 {
    margin: 0 0 10px 0;
    color: #2e4358;
    line-height: 1.35;
}

.index5-editor-text h1 { font-size: 18px; }
.index5-editor-text h2 { font-size: 16px; }
.index5-editor-text h3 { font-size: 14px; }

.index5-editor-text ul,
.index5-editor-text ol {
    margin: 0 0 12px 18px;
    padding: 0;
}

.index5-editor-text li {
    margin: 0 0 6px 0;
    font-size: 13px;
}

.index5-editor-text a {
    color: #003399;
    text-decoration: none;
}

.index5-editor-text a:hover {
    text-decoration: underline;
}

.index5-editor-text blockquote {
    margin: 0 0 12px 0;
    padding: 10px 12px;
    border-left: 3px solid #92adc9;
    background: #f6f9fc;
    color: #3f5162;
}

/* Abas textuais do ecossistema: quebra automática + rolagem interna */
.city-section-scrollable {
    max-height: none;
    overflow: visible;
    word-break: break-word;
    overflow-wrap: anywhere;
    white-space: normal;
    padding-right: 0;
    width: 100%;
    min-width: 0;
}

.city-section-scrollable::-webkit-scrollbar {
    width: 8px;
}

.city-section-scrollable::-webkit-scrollbar-track {
    background: #e7ebef;
    border-radius: 8px;
}

.city-section-scrollable::-webkit-scrollbar-thumb {
    background: #9fb0c0;
    border-radius: 8px;
}

/* ============================================
   CONTEÚDO DOS LUGARES DA CIDADE
   ============================================ */

.city-places-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.city-place-item {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 15px;
    padding: 15px 0;
    width: 100%;
}


.city-place-image {
    flex-shrink: 0;
}

.city-place-image-link {
    width: 85px;
    height: 85px;
    border: 1px solid #cfcfcf;
    border-radius: 4px;
    background-color: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-decoration: none;
}

.city-place-placeholder {
    width: 85px;
    height: 85px;
    background-color: #BEBEBE;
}

.city-place-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.city-place-title {
    color: #333333;
    font-size: 14px;
    font-weight: bold;
    margin: 0;
    padding: 0;
    line-height: 1.4;
    word-wrap: break-word;
}

.city-place-title-link {
    color: inherit;
    text-decoration: none;
}

.city-place-title-link:hover {
    text-decoration: underline;
}

.city-place-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.city-place-details p {
    color: #666666;
    font-size: 10px;
    margin: 0;
    padding: 0;
    line-height: 1.4;
}

.city-place-details .news-details-label {
    color: #666666;
}

.city-place-details .news-details-link {
    color: #003399;
    text-decoration: none;
}

.city-place-details .news-details-link:hover {
    text-decoration: underline;
}

.city-place-details .news-details-value {
    color: #666666;
}

.city-place-social {
    display: flex;
    gap: 10px;
    margin-top: 8px;
}

.city-place-social-link {
    width: 28px;
    height: 28px;
    background-color: transparent;
    border: 1px solid #999999;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333333;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.3s;
}

.city-place-social-link:hover {
    background-color: #F0F0F0;
    border-color: #666666;
}

.city-places-footer {
    text-align: right;
    padding-top: 15px;
    margin-top: 10px;
}

.city-places-footer .city-list-all-btn {
    display: inline-block;
}

/* ============================================
   PADRÃO INDEX 5 (APLICADO GLOBALMENTE)
   ============================================ */

.assistente-section {
    margin-top: 0;
}

.assistente-section .assistente-title-text {
    font-size: 20px;
    font-weight: bold;
}

.assistente-section .city-name,
.assistente-section .city-uf,
.assistente-section .city-links .city-link {
    color: #FFFFFF;
}

.city-nav-btn {
    text-decoration: none;
}

.city-dropdown-list {
    display: flex;
    flex-direction: column;
}

.city-dropdown-link {
    padding: 10px 15px;
    border-bottom: 1px solid #ececec;
    color: #444444;
    text-decoration: none;
    font-size: 13px;
}

.city-dropdown-link:hover {
    background: #f7f7f7;
}

.ecossistema-guia-dropdown {
    background: #d7e2ec;
    border-top: none;
    border-bottom: none;
}

.ecossistema-guia-dropdown.active {
    max-height: none;
    overflow: visible;
    border-top: 1px solid rgba(255, 255, 255, 0.35);
    border-bottom: 1px solid rgba(146, 173, 201, 0.45);
}

@media (max-width: 767px) {
    .city-section-content.active { max-height: none; }
    .city-section-scrollable { max-height: none; }
    .ecossistema-guia-dropdown.active { max-height: none; }
}

.ecossistema-guia-dropdown .city-dropdown-list {
    background: transparent;
}

.ecossistema-guia-dropdown .city-dropdown-link {
    padding: 10px 16px;
    font-size: 13px;
    color: #30485f;
    border-bottom: 1px solid rgba(146, 173, 201, 0.35);
    background: transparent;
}

.ecossistema-guia-dropdown .city-dropdown-link:hover {
    background: rgba(255, 255, 255, 0.55);
}

.assistente-placeholder {
    border: none;
    width: calc(100% - 30px);
    height: auto;
    background: transparent;
    margin: 0 15px;
    padding: 0;
    overflow: visible;
    cursor: pointer;
}

.assistente-placeholder-img {
    width: 100%;
    height: auto;
    object-fit: contain;
    object-position: top center;
    display: block;
    border-radius: 20px;
}

.city-info-header .city-name a,
.city-info-header .city-name a:hover,
.city-info-header .city-name a:focus,
.city-info-header .city-name a:active,
.city-info-header .city-name a:visited {
    color: inherit;
    text-decoration: none;
}

.city-news-image-btn img {
    width: 85px;
    height: auto;
    object-fit: contain;
    object-position: top center;
    display: block;
}

.city-place-image-link {
    width: 85px;
    height: 85px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.city-place-image-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

#section-assistente-top-5 {
    max-height: none;
    overflow: visible;
    transition: max-height 0.3s ease, padding 0.3s ease, margin-top 0.3s ease;
}

#section-assistente-top-5.active {
    display: block;
}

#section-assistente-top-5:not(.active) {
    max-height: 0;
    overflow: hidden;
    padding-top: 0;
    padding-bottom: 0;
    margin-top: 0;
    display: none;
}

/* index=6 mantém compatibilidade com o mesmo comportamento do componente principal */
.color-6 #section-assistente-top-5 {
    max-height: none;
    overflow: visible;
}

.color-6 #section-assistente-top-5:not(.active) {
    max-height: 0;
    overflow: hidden;
}
