﻿#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

:root {
    font-size: var(--rz-root-font-size);
}

body {
    font-family: var(--rz-text-font-family);
    color: var(--rz-text-color);
    font-size: var(--rz-body-font-size);
    line-height: var(--rz-body-line-height);
    background-color: var(--rz-body-background-color);
}

.rz-body {
    --rz-body-padding: 0;
}

.asd-shell {
    min-height: 100vh;
}

.asd-header {
    position: static;
    box-shadow: var(--rz-shadow-1);
    z-index: 10;
}



.asd-main-bar {
    min-height: 52px;
    padding-inline: 0.25rem;
}

.asd-brand-area,
.asd-menu-area {
    display: flex;
    align-items: center;
}

.asd-logo-link {
    display: inline-flex;
    align-items: center;
}

.asd-logo {
    height: 34px;
    width: auto;
}

.asd-top-menu {
    width: 100%;
    justify-content: center;
}

/* Barra de cima larga: o menu ocupa o espaço que sobra entre a marca e o usuário (são muitas abas), com as abas mais juntas e sem a setinha. */
@media (min-width: 1081px) {
    .asd-main-bar > .asd-brand-area, .asd-main-bar > .asd-user-area { flex: 0 0 auto; max-width: none; width: auto; }
    .asd-main-bar > .asd-brand-area { padding-right: 1rem; }
    .asd-main-bar > .asd-menu-area { flex: 1 1 0; max-width: none; min-width: 0; }
    .asd-top-menu > .rz-navigation-item > .rz-navigation-item-wrapper .rz-navigation-item-link { padding-inline: 0.55rem; }
    .asd-top-menu { justify-content: safe center; }
    .asd-top-menu > .rz-navigation-item > .rz-navigation-item-wrapper .rz-navigation-item-icon-children { display: none; }
}
@media (min-width: 1081px) and (max-width: 1440px) {
    .asd-main-bar > .asd-brand-area { padding-right: 0.25rem; }
    .asd-top-menu > .rz-navigation-item > .rz-navigation-item-wrapper .rz-navigation-item-link { padding-inline: 0.3rem; }
}

.asd-body-row {
    margin-inline: auto;
    max-width: 1440px;
    padding: 1rem;
}

.asd-sidebar-brand {
    padding: var(--rz-panel-menu-item-padding);
    border-bottom: var(--rz-panel-menu-item-border);
}

.h6{
    font-family: &quot;Book Antiqua&quot;, serif; 
    font-size: 6.5pt;
     margin: 0px 0px 2px;
      color: rgb(85, 85, 85);
       text-transform: uppercase;
        letter-spacing: 0.2px;
         line-height: 1.2;
}

.asd-sidebar-logo {
    width: 160px;
    max-width: 80%;
    height: auto;
}

.asd-sidebar-title {
    color: var(--rz-sidebar-color);
}

.asd-sidebar-footer {
    padding: var(--rz-panel-menu-item-padding);
}

.asd-user-area .asd-user-name, .asd-user-name.rz-text-caption {
    color: rgba(255, 255, 255, .95);
    max-width: 11rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rz-menu:not(.rz-profile-menu) {
    justify-content: center;
}

.rz-navigation-menu {
    position: relative !important;
    overflow: visible !important;
    z-index: 1000;
}

.rz-navigation-item > .rz-navigation-menu {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    z-index: 1000 !important;
}

.rz-navigation-item.rz-state-expanded > .rz-navigation-menu,
.rz-navigation-item.rz-state-active > .rz-navigation-menu,
.rz-navigation-item.rz-open > .rz-navigation-menu {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transform: none !important;
}

.rz-navigation-item:hover > .rz-navigation-menu {
    display: block !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

/* Menu do perfil: o submenu era posicionado pela lista (que tem 8px de padding), não pelo item.
   Sobrava uma faixa fora do item entre ele e o submenu; ao passar o mouse por ela, o :hover acabava e o menu fechava. */
.rz-profile-menu > .rz-navigation-item {
    position: relative;
}

.rz-profile-menu > .rz-navigation-item > .rz-navigation-menu {
    left: auto !important;
    right: 0 !important;
    min-width: 100%;
}

.rz-navigation-menu .rz-navigation-item:hover > .rz-navigation-menu {
    position: absolute !important;
    top: 0 !important;
    left: 100% !important;
    display: block !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: none !important;
}

.rz-navigation-item-icon-children.rz-state-expanded {
    transform: none !important;
    transition: none !important;
}

.rz-pager .rz-dropdown {
    width: 85px !important;
    padding: 8px !important;
    overflow-y: auto !important;
}

.index-dashboard {
    width: 100%;
}

.dashboard-panel {
    height: 100%;
    padding: 1rem;
}

.dashboard-title {
    font-weight: 700;
    margin-bottom: 0;
}

.dashboard-subtitle {
    color: var(--rz-text-secondary-color);
}

.calendar-panel {
    min-height: 100%;
}

.calendar-toolbar {
    margin-bottom: 0.75rem;
}

.calendar-title {
    margin-bottom: 1rem;
    text-transform: capitalize;
}

.calendar-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0.25rem;
    text-align: center;
}

.calendar-table th {
    color: var(--rz-text-secondary-color);
    font-size: 0.85rem;
    font-weight: 700;
    padding: 0.25rem;
    text-transform: capitalize;
}

.calendar-table td {
    height: 2.75rem;
    padding: 0;
}

.calendar-day {
    width: 2.35rem;
    height: 2.35rem;
    border: 0;
    border-radius: 999px;
    color: var(--rz-text-color);
    background: transparent;
    font: inherit;
    cursor: pointer;
}

.calendar-day:hover {
    background: var(--rz-primary-lighter);
    color: var(--rz-primary-dark);
}

.calendar-day.weekend {
    color: var(--rz-danger);
}

.calendar-day.today {
    background: var(--rz-primary);
    color: var(--rz-on-primary);
    font-weight: 700;
}

.calendar-day.holiday {
    background: var(--rz-danger);
    color: var(--rz-on-danger);
    font-weight: 700;
}

.calendar-day.today.holiday {
    box-shadow: 0 0 0 3px var(--rz-primary-lighter);
}

.calendar-legend {
    color: var(--rz-text-secondary-color);
    font-size: 0.8rem;
    margin-top: 1rem;
}

.legend-dot {
    display: inline-block;
    width: 0.7rem;
    height: 0.7rem;
    margin-right: 0.35rem;
    border-radius: 999px;
    vertical-align: middle;
}

.legend-dot.today {
    background: var(--rz-primary);
}

.legend-dot.holiday {
    background: var(--rz-danger);
}

.legend-dot.weekend {
    background: var(--rz-danger-light);
}

.status-heading {
    margin-bottom: 1rem;
}

.status-grid {
    margin-bottom: 1rem;
}

.metric-card {
    height: 100%;
    padding: 1rem;
}

.metric-icon {
    flex: 0 0 auto;
    color: var(--rz-primary);
    font-size: 2.25rem;
}

.metric-icon.info {
    color: var(--rz-info);
}

.metric-icon.warning {
    color: var(--rz-warning-dark);
}

.metric-icon.success {
    color: var(--rz-success);
}

.metric-content {
    min-width: 0;
    width: 100%;
}

.process-card {
    padding: 1rem;
}

.birth-form,
.marriage-form {
    display: block;
    width: 100%;
}

.birth-form-header,
.marriage-form-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.25rem 0 1rem;
}

.birth-form-title,
.marriage-form-title {
    margin: 0;
    font-weight: 700;
}

.birth-form-subtitle,
.marriage-form-subtitle {
    color: var(--rz-text-tertiary-color);
}

.birth-tabs,
.marriage-tabs {
    width: 100%;
}

.birth-panel,
.marriage-panel {
    padding: 1rem 0.25rem 0.25rem;
}

.birth-section-heading,
.marriage-section-heading {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--rz-base-300);
}

.birth-field,
.marriage-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-bottom: 1rem;
}

.birth-check-field,
.marriage-check-field {
    min-height: 4.65rem;
    justify-content: center;
}

.birth-check-field .rz-chkbox,
.marriage-check-field .rz-chkbox {
    margin-bottom: 0.15rem;
}

.field-code {
    color: var(--rz-text-tertiary-color);
    font-size: 0.75rem;
    line-height: 1.2;
}

.birth-form-actions,
.marriage-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--rz-base-300);
}

.birth-header-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.4rem;
}

.birth-system-note {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--rz-base-300);
    border-radius: 6px;
    color: var(--rz-text-secondary-color);
    background: var(--rz-base-100);
    font-size: 0.875rem;
}

.birth-field-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
}

.birth-system-field {
    background: var(--rz-base-100);
}

.birth-validation-list {
    margin: 0;
    padding-left: 1.25rem;
}

.birth-error-detail {
    margin-top: 0.5rem;
    font-size: 0.82rem;
    line-height: 1.35;
    opacity: 0.9;
    word-break: break-word;
}

.birth-list-page, .ato-list-page {
    width: 100%;
}

.birth-grid-primary, .ato-grid-primary {
    font-weight: 700;
}

.birth-grid-muted, .ato-grid-muted {
    color: var(--rz-text-tertiary-color);
    font-size: 0.8rem;
    line-height: 1.35;
}

.birth-grid-code, .ato-grid-code {
    color: var(--rz-text-tertiary-color);
    font-size: 0.72rem;
    line-height: 1.25;
}

.birth-grid-badges, .ato-grid-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-top: 0.35rem;
}

.birth-grid-badge, .ato-grid-badge {
    margin-left: 0.35rem;
}

.birth-row-highlight, .ato-row-highlight {
    --rz-grid-cell-background-color: color-mix(in srgb, var(--rz-primary) 10%, var(--rz-base-background-color));
    outline: 2px solid color-mix(in srgb, var(--rz-primary) 55%, transparent);
    outline-offset: -2px;
}

.birth-row-highlight td, .ato-row-highlight td {
    background: color-mix(in srgb, var(--rz-primary) 10%, var(--rz-base-background-color)) !important;
}

.birth-popup-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 2.5rem;
}

.birth-action-popup {
    display: none;
    position: absolute;
    overflow: hidden;
    width: 280px;
    border: var(--rz-panel-border);
    border-radius: 6px;
    background-color: var(--rz-panel-background-color);
    box-shadow: var(--rz-panel-shadow);
    z-index: 1200;
}

.birth-action-popup-content {
    padding: 0.75rem;
}

.birth-action-popup-header {
    display: grid;
    gap: 0.15rem;
    padding: 0.15rem 0.25rem 0.5rem;
    border-bottom: 1px solid var(--rz-base-300);
    margin-bottom: 0.35rem;
}

.birth-action-popup-header strong {
    font-size: 0.92rem;
}

.birth-action-popup-header span {
    color: var(--rz-text-tertiary-color);
    font-size: 0.78rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.birth-action-popup .rz-button {
    justify-content: flex-start;
    width: 100%;
}

.tela-carregando {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.2);
}

.loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    height: 60px;
}

.dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: var(--rz-primary);
    animation: bounce 1.2s infinite;
}

.dot1 {
    animation-delay: 0s;
}

.dot2 {
    animation-delay: 0.2s;
}

.dot3 {
    animation-delay: 0.4s;
}

.loading-message {
    margin-top: 10px;
    color: var(--rz-primary);
    font-size: 1.35rem;
    font-weight: 700;
}

@keyframes bounce {
    0%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-18px);
    }
}

a {
    color: var(--rz-link-color);
}

a:hover,
a:focus {
    color: var(--rz-link-hover-color);
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTT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uMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem auto;
}

.loading-progress circle {
    fill: none;
    stroke: #e0e0e0;
    stroke-width: 0.6rem;
    transform-origin: 50% 50%;
    transform: rotate(-90deg);
}

.loading-progress circle:last-child {
    stroke: #1b6ec2;
    stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
    transition: stroke-dasharray 0.05s ease-in-out;
}

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

.loading-progress-text:after {
    content: var(--blazor-load-percentage-text, "Carregando...");
}

@media (max-width: 1080px) {
    .asd-main-bar {
        row-gap: 0.35rem;
        padding-block: 0.35rem;
    }

    .asd-brand-area,
    .asd-menu-area {
        max-width: 100% !important;
        flex-basis: 100% !important;
        justify-content: center;
    }

    .asd-body-row {
        padding: 0.75rem;
    }

    .calendar-table td {
        height: 2.35rem;
    }

    .calendar-day {
        width: 2rem;
        height: 2rem;
    }
}

.rz-html-editor-content{
    color: black;
}

.icd-card{
    width: 250px;
}
/* Menu: item sem direito (Segurança › Direitos dos usuários) — escurecido, com cadeado e sem link */
.asd-bloqueado > .rz-navigation-item-wrapper { opacity: 0.55; cursor: not-allowed; }
.asd-bloqueado > .rz-navigation-item-wrapper .rz-navigation-item-text::after {
    content: "lock"; font-family: var(--rz-icon-font-family); font-feature-settings: "liga"; font-weight: normal;
    font-size: 1rem; line-height: 1; vertical-align: -0.15em; margin-left: 0.45rem;
}
.asd-bloqueado > .rz-navigation-item-wrapper .rz-navigation-item-icon-children { display: none; }

/* Abas que não cabem na largura quebram linha em vez de sumir pela direita (Minha Serventia). */
.asd-abas-quebram > .rz-tabview-nav { flex-wrap: wrap; row-gap: 0.25rem; }

/* Menu: aba afastada das outras por um traço (Centrais, no fim) */
.asd-top-menu > .asd-menu-separado { margin-left: 0.5rem; padding-left: 0.5rem; border-left: 1px solid color-mix(in srgb, currentColor 45%, transparent); }

/* Menu: tela ainda em construção (ícone de obra depois do texto) */
.asd-em-construcao > .rz-navigation-item-wrapper .rz-navigation-item-text::after {
    content: "construction"; font-family: var(--rz-icon-font-family); font-feature-settings: "liga"; font-weight: normal;
    font-size: 1rem; line-height: 1; vertical-align: -0.15em; margin-left: 0.45rem; color: var(--rz-warning);
}

/* REGRA: o título do campo fica na linha do contorno. Telas com RadzenLabel em cima do campo (RadzenStack título + campo): o título desce
   para a borda, como o RadzenFormField "outlined". Os editores gerados das tabelas (título ao lado) não mudam. */
.rz-stack:has(> .rz-label:first-child + :is(.rz-textbox, .rz-dropdown, .rz-numeric, .rz-datepicker, .rz-textarea, .rz-autocomplete, .rz-mask, .rz-dropdown-multiple, input.rz-inputtext, .rz-colorpicker, .documento-conferencia)):not(:has(> :nth-child(3))) {
    position: relative; gap: 0 !important; margin-top: 7px;
}
.rz-stack:has(> .rz-label:first-child + :is(.rz-textbox, .rz-dropdown, .rz-numeric, .rz-datepicker, .rz-textarea, .rz-autocomplete, .rz-mask, .rz-dropdown-multiple, input.rz-inputtext, .rz-colorpicker, .documento-conferencia)):not(:has(> :nth-child(3))) > .rz-label {
    position: absolute; top: 0; left: 10px; transform: translateY(-50%); z-index: 2; pointer-events: none; margin: 0;
    padding: 0 5px; background: var(--rz-base-background-color); color: var(--rz-text-secondary-color); font-size: .72rem; font-weight: 500; line-height: 1.25;
    max-width: calc(100% - 20px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rz-stack:has(> .rz-label:first-child):focus-within > .rz-label { color: var(--rz-primary); }

/* Menu: traço que separa os blocos (inclusão, pesquisa, demais, configurações). */
.rz-navigation-menu .asd-menu-traco { border-top: 1px solid var(--rz-base-300); margin-top: 3px; padding-top: 3px; }

/* Faixa do topo (CNS / nome da serventia): texto claro sobre a barra (azul-marinho no claro, cinza-escuro no escuro). */
.asd-servantia-title.rz-text-subtitle2 {
    color: rgba(255, 255, 255, .92);
}
.documento-conferencia { width:100%; min-width:0; }
.documento-conferencia > .rz-textbox { width:100%; }
