/* Identidade visual do CerimonialVIP sobre o Material Dashboard */
.ow-hero {
    background: linear-gradient(135deg, #f7d6e0 0%, #e91e63 55%, #ad1457 100%);
    color: #fff;
    border-radius: 0.75rem;
}
.ow-hero .ow-contagem {
    font-family: 'Roboto Slab', serif;
    font-size: 3.25rem;
    line-height: 1;
    font-weight: 700;
}
.ow-hero h3, .ow-hero h5, .ow-hero p { color: #fff; }

.ow-tabela { font-size: 12px; }
.ow-tabela th, .ow-tabela td { padding: 4px 6px; white-space: nowrap; }

.ow-timeline { position: relative; padding-left: 2.25rem; }
.ow-timeline::before {
    content: '';
    position: absolute;
    left: 0.9rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: 2px;
    background: #f3c1d3;
}
.ow-timeline .ow-etapa { position: relative; }
.ow-timeline .ow-marcador {
    position: absolute;
    left: -2.25rem;
    top: 1.1rem;
    width: 1.8rem;
    height: 1.8rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    box-shadow: 0 0 0 4px #f0f2f5;
}

.ow-check { border: 0; background: transparent; padding: 0; line-height: 1; cursor: pointer; }
.ow-check .material-icons { font-size: 1.4rem; }
.ow-concluida { text-decoration: line-through; opacity: 0.6; }
.ow-dica { font-size: 0.75rem; color: #7b809a; white-space: normal; }

.ow-kpi .numero { font-size: 1.5rem; font-weight: 700; color: #344767; }

.fc .fc-toolbar-title { font-size: 1.1rem; text-transform: capitalize; }
.fc .fc-event { cursor: pointer; }

/* Assistente de IA do briefing */
.ow-ia-botao {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 56px;
    height: 56px;
    padding: 0;
    z-index: 1040;
}
.ow-ia-botao .material-icons { font-size: 1.6rem; }
.ow-ia-painel {
    position: fixed;
    right: 24px;
    bottom: 92px;
    width: 380px;
    max-width: calc(100vw - 32px);
    height: 70vh;
    max-height: 640px;
    z-index: 1041;
    display: flex;
    flex-direction: column;
}
.ow-ia-painel.d-none { display: none !important; }
.ow-ia-mensagens { overflow-y: auto; flex: 1 1 auto; background: #f8f9fa; }
.ow-ia-msg {
    max-width: 88%;
    padding: 8px 12px;
    border-radius: 12px;
    margin-bottom: 8px;
    font-size: 0.85rem;
    white-space: pre-line;
    word-wrap: break-word;
}
.ow-ia-assistente { background: #fff; color: #344767; border: 1px solid #eceff4; }
.ow-ia-usuario { background: #e91e63; color: #fff; margin-left: auto; }
.ow-ia-erro { background: #fdecea; color: #b71c1c; }
.ow-ia-digitando { font-style: italic; opacity: 0.7; }
.ow-ia-ref { font-size: 0.7rem; opacity: 0.85; margin-bottom: 2px; }
.ow-sugestao {
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #fdf2f6;
    border: 1px dashed #f3a6c2;
    font-size: 0.85rem;
}
.ow-sugestao-texto { white-space: pre-line; color: #344767; }
.ow-sugestao-erro { background: #fdecea; border-color: #f5c2c0; color: #b71c1c; }
@media print { .ow-ia-botao, .ow-ia-painel { display: none !important; } }

/* Choices.js aplicado em todos os selects (cerimonialvip-choices.js) */
.choices { margin-bottom: 0; }
.input-group > .choices { flex: 1 1 100%; width: 100%; }
.choices.is-invalid .choices__inner { border-color: #F44335 !important; }

/*
 * Tabela que se ajusta à largura da tela, sem scroll horizontal.
 * - A coluna .ow-principal (padrão: a 1ª) fica com o espaço livre; as demais encolhem ao conteúdo.
 * - .ow-quebra: coluna de texto longo que pode quebrar linha.
 * - .ow-col-md / .ow-col-lg no <th>: coluna some em telas médias/menores que 1400px.
 * - Celular (< 576px): cada linha vira um cartão "Rótulo: valor" (nada é escondido).
 * Rótulos e classes do <th> são copiados para os <td> por js/cerimonialvip-tabelas.js.
 */
.ow-tabela-fluida { width: 100%; }
.ow-tabela-fluida th, .ow-tabela-fluida td { padding: 6px 8px; }
.dataTable-wrapper .dataTable-container .ow-tabela-fluida thead tr th,
.dataTable-wrapper .dataTable-container .ow-tabela-fluida tbody tr td { padding: 6px 8px; }
.ow-tabela-fluida th, .ow-tabela-fluida td { width: 1%; white-space: nowrap; }
.ow-tabela-fluida th.ow-principal, .ow-tabela-fluida td.ow-principal { width: auto; white-space: normal; min-width: 7rem; overflow-wrap: break-word; }
.ow-tabela-fluida th.ow-quebra, .ow-tabela-fluida td.ow-quebra { width: auto; white-space: normal; min-width: 7rem; }
.ow-tabela-fluida .ow-detalhe { display: none; }
.ow-tabela-fluida .ow-detalhe [data-txt]::after { content: attr(data-txt); }
.ow-tabela-fluida .ow-detalhe-sm { display: none; }

@media (min-width: 576px) and (max-width: 1399.98px) {
    .ow-tabela-fluida .ow-col-lg { display: none; }
    .ow-tabela-fluida .ow-detalhe { display: block; }
}
@media (min-width: 576px) and (max-width: 991.98px) {
    .ow-tabela-fluida .ow-col-md { display: none; }
}
@media (min-width: 992px) {
    .ow-tabela-fluida .ow-detalhe-md { display: none; }
}

/* Celular: linhas em formato de cartão */
@media (max-width: 575.98px) {
    .ow-tabela-fluida, .ow-tabela-fluida tbody, .ow-tabela-fluida tr, .ow-tabela-fluida td { display: block; width: 100% !important; }
    .ow-tabela-fluida { border: 0 !important; }
    .ow-tabela-fluida thead { display: none; }
    .ow-tabela-fluida tbody tr { display: flex; flex-direction: column; border: 1px solid #e9ecef; border-radius: 0.5rem; margin-bottom: 0.75rem; padding: 0.25rem 0; }
    .ow-tabela-fluida tbody tr td,
    .dataTable-wrapper .dataTable-container .ow-tabela-fluida tbody tr td {
        display: block; border: 0; padding: 3px 10px; white-space: normal; text-align: right !important; min-width: 0;
    }
    .ow-tabela-fluida tbody tr td::after { content: ''; display: table; clear: both; }
    .ow-tabela-fluida tbody tr td::before {
        content: attr(data-label); float: left; margin-right: 0.75rem; text-align: left; line-height: 1.6rem;
        font-size: 0.7rem; font-weight: 700; text-transform: uppercase; color: #7b809a;
    }
    /* A coluna principal vira o título do cartão; a última (ações) fica alinhada à direita sem rótulo */
    .ow-tabela-fluida tbody tr td.ow-principal,
    .dataTable-wrapper .dataTable-container .ow-tabela-fluida tbody tr td.ow-principal { order: -1; display: block; text-align: left !important; font-weight: 600; }
    .ow-tabela-fluida tbody tr td.ow-principal::before,
    .ow-tabela-fluida tbody tr td[data-label=""]::before { content: none; }
    .ow-tabela-fluida .ow-detalhe { display: none; }
}

/* Editor de texto longo (ex.: modelo de contrato) que ocupa a altura livre da tela, mantendo os botões visíveis */
@media (min-width: 992px) {
    .ow-editor-altura { height: calc(100vh - 360px); min-height: 240px; }
}

/* Lista de presentes: ícone no lugar da foto */
.ow-presente-icone { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; flex-shrink: 0; border-radius: .5rem; background: #fce4ec; color: #c2185b; }
.ow-presente-icone .material-icons-round { font-size: 22px; }

/* Manuais do sistema */
.ow-manual-imagem { display: block; width: 100%; height: auto; border: 1px solid #e9ecef; border-radius: .75rem; box-shadow: 0 4px 16px rgba(0, 0, 0, .06); cursor: zoom-in; }
.ow-manual-imagem-celular { width: auto; max-width: 320px; }
.ow-manual-dica { background: #fff8e1; border-radius: .5rem; padding: .6rem .8rem; }
.ow-manual-nav a:hover { color: #e91e63 !important; }

/* Apresentação comercial (Manuais → Apresentação Comercial) */
.ow-apre { border-radius: 1rem; overflow: hidden; box-shadow: 0 4px 20px rgba(0, 0, 0, .08); }
.ow-apre:fullscreen { overflow-y: auto; border-radius: 0; background: #fff; scroll-behavior: smooth; }
.ow-apre:fullscreen .ow-apre-slide { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; }
.ow-apre-slide { padding: 3.5rem 3rem; }
.ow-apre-capa { background: linear-gradient(135deg, #EC407A 0%, #AD1457 100%); }
.ow-apre-claro { background: #fdf2f6; }
.ow-apre-chamada { font-size: 2.6rem; line-height: 1.15; }
.ow-apre-selo { display: inline-block; padding: .3rem .9rem; border-radius: 2rem; background: rgba(255, 255, 255, .2); font-weight: 700; font-size: .8rem; letter-spacing: .05em; text-transform: uppercase; }
.ow-apre-navegador { background: #f1f3f4; border-radius: .9rem; overflow: hidden; box-shadow: 0 18px 40px rgba(0, 0, 0, .18); }
.ow-apre-navegador-barra { height: 28px; display: flex; align-items: center; gap: 6px; padding: 0 12px; }
.ow-apre-navegador-barra span { width: 10px; height: 10px; border-radius: 50%; background: #ff5f57; }
.ow-apre-navegador-barra span:nth-child(2) { background: #febc2e; }
.ow-apre-navegador-barra span:nth-child(3) { background: #28c840; }
.ow-apre-corte { display: block; width: 100%; height: auto; aspect-ratio: 1366 / 820; object-fit: cover; object-position: top; cursor: zoom-in; }
.ow-apre-celular { width: 240px; padding: 10px; background: #1a1a1a; border-radius: 2.2rem; box-shadow: 0 18px 40px rgba(0, 0, 0, .3); }
.ow-apre-celular img { display: block; width: 100%; height: 470px; object-fit: cover; object-position: top; border-radius: 1.6rem; }
.ow-apre-recurso { background: #fff; border: 1px solid #f0e4ea; border-radius: .75rem; padding: 1rem; }
.ow-apre-plano { background: #fff; border: 1px solid #e9ecef; border-radius: 1rem; padding: 1.5rem; text-align: center; }
.ow-apre-plano-destaque { border: 2px solid #e91e63; box-shadow: 0 10px 30px rgba(233, 30, 99, .15); }
@media (max-width: 767.98px) {
    .ow-apre-slide { padding: 2rem 1.25rem; }
    .ow-apre-chamada { font-size: 1.9rem; }
}

@media print {
    #sidenav-main, .navbar-main, .ow-manual-indice, .ow-nao-imprimir, footer, .fixed-plugin { display: none !important; }
    .main-content, .g-sidenav-show .main-content { margin: 0 !important; }
    .main-content .col-xl-9 { flex: 0 0 100%; max-width: 100%; }
    .ow-manual-capitulo { break-before: page; box-shadow: none !important; border: 0 !important; }
    .ow-manual-secao { break-inside: avoid; }
    .ow-manual-imagem { max-height: 15cm; width: auto; max-width: 100%; box-shadow: none; }
    .ow-apre { box-shadow: none; border-radius: 0; }
    .ow-apre-slide { break-inside: avoid; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    .card { box-shadow: none !important; }
}

/* Badge do evento selecionado no navbar: mantém texto branco no hover */
.ow-evento-badge,
.ow-evento-badge:hover,
.ow-evento-badge:focus { color: #fff !important; }
.ow-evento-badge:hover { opacity: .85; }

/* Notificações: tabela de preferências sem rolagem horizontal; a coluna Aviso quebra linha */
.ow-tabela-notif { width: 100%; table-layout: fixed; }
.ow-tabela-notif th.ow-aviso, .ow-tabela-notif td.ow-aviso { white-space: normal; overflow-wrap: break-word; width: auto; }
.ow-tabela-notif th.ow-publico, .ow-tabela-notif td.ow-publico { white-space: normal; width: 6.5rem; line-height: 1.2; padding-left: 2px; padding-right: 2px; }
.ow-tabela-notif td[colspan] { white-space: normal; }
@media (max-width: 575.98px) {
    .ow-tabela-notif th.ow-publico, .ow-tabela-notif td.ow-publico { width: 3.6rem; font-size: 10px; }
    .ow-tabela-notif td.ow-publico label { display: block; margin: 2px 0 !important; }
}

/* Cadastro: aviso de que a conta é para assessorias (noivos recebem o acesso da assessoria) */
.ow-aviso-noivos { background: #fdf2f6; color: #7b1fa2; border-radius: .5rem; padding: .5rem .7rem; line-height: 1.4; }
.ow-aviso-noivos strong { color: #ad1457; }
