/* ---------- Módulo Negociação de Acordo Coletivo ---------- */
/* Página irmã de /convencao-coletiva: usa os mesmos tokens
   (--stmc-*, --shadow-*, --radius-*) e as mesmas classes de cct.css
   (.cct-pillar, .cct-form-card, .cct-stepper, .cct-progress, .cct-field...).
   Este arquivo só traz o que é próprio da negociação. */

/* O preenchimento da barra divide pelo total de etapas do formulário. */
.neg-form {
    --cct-total: 2;
}

/* --- Apresentação --- */
.neg-hero-acoes {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.5rem;
}

.page-act #solicitar {
    --service-form-kicker: "Solicitar ACT";
}

body:has(#negConfirmado) .cct-confirm {
    width: min(100%, 36rem);
    box-sizing: border-box;
    container-type: inline-size;
}

.cct-confirm-destaque .cct-confirm-valor {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
    min-width: 0;
}

.cct-confirm-destaque .cct-confirm-valor strong {
    min-width: 0;
    overflow-wrap: anywhere;
}

.cct-confirm-destaque #btnCopiarProtocolo {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: auto !important;
    min-width: 0;
    margin: 0 !important;
    white-space: nowrap;
}

.neg-confirm-contatos {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 1rem;
    min-width: 0;
}

.neg-confirm-contatos a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    max-width: 100%;
    overflow-wrap: anywhere;
    color: var(--stmc-red-dark);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.neg-confirm-contatos a:hover,
.neg-confirm-contatos a:focus-visible {
    color: var(--stmc-red);
}

.neg-confirm-contatos a:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

.neg-confirm-contatos [hidden] {
    display: none !important;
}

@container (max-width: 34rem) {
    .cct-confirm-row {
        align-items: flex-start;
        gap: 0.25rem;
        padding: 0.75rem clamp(0.75rem, 4cqi, 1rem);
    }

    .cct-confirm-label,
    .cct-confirm-valor {
        flex: 1 1 100%;
        min-width: 0;
    }

    .cct-confirm-destaque .cct-confirm-valor {
        align-items: center;
    }

    .neg-confirm-contatos {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

body.page-act .cct-hero-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
}

body.page-act .cct-hero-copy {
    min-width: 0;
    width: 100%;
}

body.page-act .cct-hero-copy .odonto-hero-text {
    max-width: 68rem;
}

body.page-act #duvidas .odonto-faq-btn {
    min-width: 44px;
    min-height: 44px;
    cursor: pointer;
}

@media (max-width: 991.98px) {
    body.page-act .cct-hero-copy > .neg-hero-acoes,
    body.page-act .cct-hero-copy > .odonto-note {
        display: none;
    }
}

body.page-act #duvidas .odonto-faq-btn:focus-visible,
body.page-act .cct-step-title:focus-visible {
    position: relative;
    z-index: 1;
    outline: 3px solid var(--stmc-red);
    outline-offset: -3px;
}

body.page-act #duvidas .odonto-faq-btn > .bi-chevron-down {
    transition: transform 180ms ease;
}

body.page-act #duvidas .odonto-faq-btn[aria-expanded="true"] > .bi-chevron-down {
    transform: rotate(180deg);
}

@media (max-width: 767.98px) {
    body:has(#negConfirmado) main {
        padding-bottom: clamp(1rem, 4vi, 1.5rem);
    }

    body:has(#negConfirmado) #confirmacao {
        padding-block-end: 1rem;
    }

    #negConfirmado > .odonto-note {
        margin-block-end: 0.5rem;
    }

    .cct-hero-copy > .odonto-hero-text {
        display: block;
        overflow: visible;
    }

    .neg-form .cct-stepper-item.is-current::after {
        content: "Etapa " attr(data-etapa) " de 2";
    }

    .neg-form .cct-stepper {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .neg-hero-acoes + .odonto-note,
    .neg-hero-acoes {
        width: 100%;
        max-width: none;
    }

    body.page-act main > section > .container {
        width: min(calc(100% - 40px), 1180px);
        max-width: none;
        padding-inline: 0;
    }

    /* Mantém o ritmo compacto da home; evita a faixa vazia criada pelo
       --section-py global nas páginas de serviço. */
    body.page-act main > section {
        padding-block: 24px;
    }

    body.page-act main > section + section {
        margin-block-start: 0;
    }

    body.page-act #apresentacao > .container > nav {
        margin-bottom: 24px;
    }

    body.page-act #apresentacao {
        padding-bottom: 24px;
    }

    body.page-act main {
        display: flex;
        flex-direction: column;
    }

    body.page-act #apresentacao {
        order: 1;
    }

    body.page-act #solicitar {
        order: 2;
    }

    body.page-act #garantias {
        order: 3;
    }

    body.page-act #duvidas {
        order: 4;
        display: none;
    }

    body.page-act .cct-hero-copy > .servicos-badge {
        margin-bottom: 12px;
    }

    body.page-act .cct-hero-copy > .odonto-hero-title {
        max-width: none;
        margin-bottom: 8px;
        padding-top: 0;
        font-size: clamp(1.75rem, 8.2vw, 2.35rem);
        line-height: 1.08;
    }

    body.page-act .cct-hero-copy > .odonto-hero-text:not(.editorial-copy) {
        margin-bottom: 16px;
    }

    body.page-act .neg-hero-acoes {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
        margin-top: 16px;
    }

    body.page-act .neg-hero-acoes .btn,
    body.page-act .cct-actions .btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        min-height: 48px;
        margin: 0;
        font-size: 15px;
        line-height: 1.35;
    }

    body.page-act .neg-hero-acoes .btn-primary,
    body.page-act .cct-actions .btn-primary {
        color: #fff;
    }

    body.page-act .neg-hero-acoes > .btn {
        text-align: center;
        justify-content: center;
    }

    body.page-act .neg-hero-acoes .odonto-btn-ghost,
    body.page-act .cct-actions .odonto-btn-ghost {
        color: var(--stmc-gray-900);
    }

    body.page-act .neg-hero-acoes + .odonto-note {
        margin-top: 12px;
        overflow-wrap: anywhere;
    }

    body.page-act .cct-grid {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
    }

    body.page-act .cct-form-content,
    body.page-act .cct-form-card,
    body.page-act .cct-field,
    body.page-act .cct-summary {
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        max-width: 100%;
    }

    body.page-act .cct-form-card {
        padding: 24px;
        border: 1px solid var(--stmc-gray-200);
        border-radius: 16px;
        box-shadow: 0 1px 3px rgb(0 0 0 / 0.06), 0 1px 2px rgb(0 0 0 / 0.04);
    }

    body.page-act .cct-input,
    body.page-act select,
    body.page-act textarea {
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        max-width: 100%;
        min-height: 2.75rem;
        padding: 0.625rem 0.75rem;
        font-size: 0.7375rem;
        line-height: 1.5;
    }

    body.page-act .cct-required-key {
        margin: 0 0 16px;
        padding: 0;
        font-size: 0.875rem;
        line-height: 1.65;
    }

    body.page-act .cct-progress-text {
        margin: 0 0 6px;
        color: var(--stmc-gray-600);
        font-size: 0.75rem;
        line-height: 1.65;
    }

    body.page-act .cct-step-title {
        margin: 0 0 6px;
        font-size: 1rem;
        line-height: 1.65;
        letter-spacing: 0;
    }

    body.page-act .cct-step-hint {
        margin: 0 0 20px;
        font-size: 0.875rem;
        line-height: 1.7;
    }

    body.page-act .cct-label {
        margin: 0 0 6px;
        font-size: 0.8125rem;
        line-height: 1.65;
    }

    body.page-act .cct-help,
    body.page-act .cct-error,
    body.page-act .cct-lookup {
        font-size: 0.875rem;
        line-height: 1.5;
    }

    body.page-act .cct-textarea {
        min-height: 11rem;
        line-height: 1.7;
    }

    body.page-act .cct-help,
    body.page-act .cct-error,
    body.page-act .cct-lookup {
        margin-top: 8px;
        font-size: 0.8125rem;
        line-height: 1.5;
        overflow-wrap: anywhere;
    }

    body.page-act .cct-actions {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
        margin-top: 20px;
        padding-top: 16px;
    }

    body.page-act #duvidas .odonto-faq {
        display: grid;
        gap: 12px;
        width: 100%;
        min-width: 0;
        padding: 0;
        background: transparent;
        border: 0;
        box-shadow: none;
    }

    body.page-act #duvidas .odonto-faq-item,
    body.page-act #duvidas .odonto-faq-btn,
    body.page-act #duvidas .odonto-faq-body {
        max-width: 100%;
    }

    body.page-act #duvidas .odonto-faq-item {
        overflow: hidden;
        background: #fff;
        border: 1px solid var(--stmc-gray-200);
        border-radius: 14px;
        box-shadow: 0 3px 12px rgb(17 24 39 / 0.055);
    }

    body.page-act #duvidas .odonto-faq-btn {
        display: grid;
        grid-template-columns: 40px minmax(0, 1fr) 24px;
        gap: 12px;
        box-sizing: border-box;
        width: 100%;
        min-height: 72px;
        padding: 12px;
        color: var(--stmc-gray-900);
        background: #fff;
        border: 0;
        border-radius: inherit;
        font-size: 0.9375rem;
        font-weight: 800;
        line-height: 1.3;
        text-align: left;
    }

    body.page-act #duvidas .odonto-faq-btn > span {
        min-width: 0;
        overflow-wrap: anywhere;
        font-size: 0.9375rem;
    }

    body.page-act #duvidas .odonto-faq-btn > .odonto-faq-icon {
        display: grid;
        place-items: center;
        width: 40px;
        height: 40px;
        color: var(--stmc-red);
        background: rgb(198 40 40 / 0.07);
        border-radius: 10px;
        font-size: 1.25rem;
    }

    body.page-act #duvidas .odonto-faq-btn[aria-expanded="true"] {
        background: rgb(198 40 40 / 0.035);
    }

    body.page-act #duvidas .odonto-faq-body {
        box-sizing: border-box;
        width: 100%;
        padding: 0 12px 16px 64px;
        color: var(--stmc-gray-600);
        font-size: 0.875rem;
        line-height: 1.55;
        overflow-wrap: anywhere;
    }

    body.page-act main {
        overflow-x: clip;
        padding-bottom: 24px;
    }

    body.page-act .cct-hero-copy > .odonto-hero-title {
        margin: 0 0 12px;
        padding-top: 0;
        font-size: clamp(1.6rem, 7.2vw, 2.05rem);
        line-height: 1.08;
    }

    body.page-act .cct-hero-copy > .odonto-hero-text {
        margin: 0 0 20px;
        padding-top: 0;
        border-top: 0;
        font-size: 0.86rem;
        line-height: 1.5;
    }

    body.page-act .cct-hero-copy > .odonto-hero-text:not(.editorial-copy) {
        margin-bottom: 20px;
    }

    body.page-act #garantias .row {
        --bs-gutter-x: 0;
        --bs-gutter-y: 0;
        display: grid;
        gap: 24px;
        margin: 16px 0 0;
    }

    body.page-act #garantias .row > [class*="col-"] {
        width: 100%;
        max-width: none;
        padding: 0;
    }

    body.page-act #garantias .cct-pillar {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "icon"
            "title"
            "lead"
            "text";
        gap: 4px;
        height: auto;
        padding: 0.75rem 0 0.75rem 1rem;
        background: transparent;
        border: 0;
        border-left: 2px solid var(--stmc-red);
        border-radius: 0;
        box-shadow: none;
    }

    body.page-act #garantias .cct-pillar-icon {
        grid-area: icon;
        justify-self: start;
        margin: 0 0 0.35rem;
        font-size: 1.125rem;
    }

    body.page-act #garantias .cct-pillar-title {
        grid-area: title;
        min-width: 0;
        margin: 0 0 4px;
        font-size: 16px;
        line-height: 1.3;
    }

    body.page-act #garantias .cct-pillar-lead {
        grid-area: lead;
        min-width: 0;
        margin: 0 0 8px;
        font-size: 14px;
        line-height: 1.5;
    }

    body.page-act #garantias .cct-pillar-text {
        grid-area: text;
        min-width: 0;
        margin: 8px 0 0;
        font-size: 14px;
        line-height: 1.5;
    }

    body.page-act .cookie-consent {
        position: fixed;
        z-index: 1070;
        inset-inline: 16px;
        bottom: calc(var(--mobile-bottom-nav-height, 68px) + env(safe-area-inset-bottom, 0px) + 8px);
        box-sizing: border-box;
        width: auto;
        max-width: none;
        max-height: min(150px, calc(100dvh - var(--mobile-bottom-nav-height, 68px) - env(safe-area-inset-bottom, 0px) - 16px));
        margin: 0;
        padding: 10px 12px;
        overflow: hidden;
    }

    body.page-act .cookie-consent-copy p {
        display: -webkit-box;
        max-height: calc(1.35em * 2);
        margin-bottom: 6px;
        overflow: hidden;
        font-size: 12px;
        line-height: 1.35;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }

    body.page-act .cookie-consent-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    body.page-act .cookie-consent-actions button {
        min-width: 0;
        min-height: 42px;
        padding: 8px;
    }

    body.page-act .page-wrapper > .whatsapp-float {
        position: static;
        width: 48px;
        height: 48px;
        margin: 16px 20px calc(var(--mobile-bottom-nav-height, 68px) + env(safe-area-inset-bottom, 0px) + 16px) auto;
    }


    .neg-form {
        box-sizing: border-box;
    }
}

@media (min-width: 992px) {
    body.page-act #apresentacao {
        padding-block: 2.5rem;
    }

    body.page-act #solicitar {
        padding-block: 2.75rem;
    }

    body.page-act #garantias {
        padding-block: 2.75rem 3.5rem;
    }

    body.page-act #apresentacao > .container > nav {
        margin-bottom: 28px;
    }

    body.page-act .neg-hero-acoes,
    body.page-act .cct-hero-copy > .odonto-note,
    body.page-act #duvidas {
        display: none;
    }
}

@media (min-width: 1024px) {
    body.page-act .cct-hero-copy > p.odonto-hero-text.editorial-copy {
        max-width: 100ch;
        text-align: left;
        text-wrap: balance;
    }
}

@media (prefers-reduced-motion: reduce) {
    body.page-act #duvidas .odonto-faq-btn,
    body.page-act #duvidas .odonto-faq-btn > .bi-chevron-down,
    body.page-act .cct-progress-fill,
    body.page-act .collapse.collapsing {
        transition: none;
    }
}

@media (pointer: coarse) {
    .neg-confirm-contatos a {
        min-height: 2.75rem;
    }
}
