:root {
    --bg: #f6f8fb;
    --surface: #ffffff;
    --surface-muted: #edf2f7;
    --text: #18212f;
    --muted: #667085;
    --line: #d9e2ec;
    --primary: #0f766e;
    --primary-dark: #115e59;
    --accent: #2563eb;
    --warning: #b45309;
    --danger: #b42318;
    --success: #067647;
    --shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
    --shadow-strong: 0 24px 70px rgba(15, 23, 42, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    display: flex;
    flex-direction: column;
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.5;
    min-height: 100vh;
}

a {
    color: inherit;
}

main {
    flex: 1 0 auto;
}

.site-header,
.site-footer {
    align-items: center;
    display: flex;
    justify-content: space-between;
    padding: 18px clamp(18px, 4vw, 56px);
}

.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    position: sticky;
    top: 0;
    z-index: 10;
}

.brand,
.site-nav,
.hero-actions,
.form-actions,
.actions,
.pagination {
    align-items: center;
    display: flex;
    gap: 12px;
}

.brand {
    font-weight: 700;
    text-decoration: none;
}

.brand-logo {
    display: block;
    height: 42px;
    max-width: min(160px, 42vw);
    object-fit: contain;
    width: auto;
}

.brand-mark {
    background: var(--text);
    color: #fff;
    display: inline-flex;
    height: 34px;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    border-radius: 6px;
}

.brand-text {
    color: var(--text);
}

.site-nav {
    flex-wrap: wrap;
    justify-content: center;
    justify-self: center;
}

.site-nav a,
.logout-form button {
    background: transparent;
    border: 0;
    color: var(--muted);
    cursor: pointer;
    font: inherit;
    padding: 8px 10px;
    text-decoration: none;
}

.site-nav a:hover,
.logout-form button:hover {
    color: var(--text);
}

.nav-action {
    border: 1px solid var(--line) !important;
    border-radius: 6px;
}

.logout-form {
    margin: 0;
}

.hero,
.page-heading,
.workspace,
.detail-page,
.form-page,
.auth-page {
    margin: 0 auto;
    max-width: 1180px;
    padding: clamp(36px, 7vw, 82px) clamp(18px, 4vw, 40px);
}

.certificates-workspace {
    max-width: min(1680px, calc(100vw - 80px));
}

.hero {
    min-height: 520px;
    align-items: center;
    display: flex;
}

.hero-content {
    max-width: 760px;
}

.editable-text {
    margin: 0;
    position: relative;
}

.editable-text [data-editable-display] {
    outline: 0;
}

.editable-text.is-editing [data-editable-display] {
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 0 0 2px var(--accent);
    border-radius: 6px;
    padding: 4px 6px;
}

.edit-pencil {
    align-items: center;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 999px;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
    color: var(--text);
    cursor: pointer;
    display: inline-flex;
    font-size: 0.9rem;
    font-weight: 700;
    height: 28px;
    justify-content: center;
    opacity: 0;
    position: absolute;
    right: -34px;
    top: 0;
    transition: opacity 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    width: 28px;
    z-index: 3;
}

.editable-text:hover .edit-pencil,
.editable-text.is-editing .edit-pencil {
    opacity: 1;
}

.edit-pencil:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.inline-edit-actions {
    display: flex;
    gap: 8px;
    margin: 8px 0 14px;
}

.inline-edit-actions[hidden] {
    display: none;
}

.inline-edit-actions .button {
    min-height: 34px;
    padding: 6px 10px;
}

.compact-editable .edit-pencil {
    right: 0;
    top: -8px;
}

.eyebrow {
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0;
    margin: 0 0 10px;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    font-size: clamp(2rem, 5vw, 4.2rem);
    line-height: 1.05;
    margin-bottom: 18px;
}

h2 {
    font-size: 1.1rem;
}

.hero p,
.page-heading p,
.workspace-heading p,
.detail-heading p {
    color: var(--muted);
    font-size: 1.04rem;
    max-width: 760px;
}

.button {
    border: 1px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    display: inline-flex;
    font-weight: 700;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    text-decoration: none;
}

.button.primary {
    background: var(--primary);
    color: #fff;
}

.button.primary:hover {
    background: var(--primary-dark);
}

.button:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.button.secondary {
    background: var(--surface);
    border-color: var(--line);
    color: var(--text);
}

.button.ghost {
    color: var(--muted);
}

.button.danger-link {
    background: #fff;
    border-color: #fecdca;
    color: var(--danger);
}

.button.full {
    width: 100%;
}

.section-grid,
.company-summary,
.proof-strip,
.content-band,
.metrics,
.filters,
.detail-grid {
    display: grid;
    gap: 16px;
    margin: 0 auto;
    max-width: 1180px;
    padding: 0 clamp(18px, 4vw, 40px) 54px;
}

.section-grid,
.company-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.section-grid article,
.company-summary > div,
.content-band > div,
.auth-panel,
.data-form,
.table-wrap,
.detail-grid,
.notes {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.section-grid article,
.company-summary > div,
.content-band > div,
.auth-panel,
.data-form,
.notes {
    padding: 24px;
}

.section-grid p,
.company-summary p,
.content-band p,
.notes p {
    color: var(--muted);
    margin-bottom: 0;
}

.client-marquee {
    background: #111827;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
    padding: 34px 0 26px;
}

.marquee-title {
    color: #99f6e4;
    font-size: 0.78rem;
    font-weight: 700;
    margin: 0 auto 18px;
    max-width: 1180px;
    padding: 0 clamp(18px, 4vw, 40px);
    text-transform: uppercase;
}

.marquee-viewport {
    margin: 0 auto;
    max-width: 1180px;
    overflow: hidden;
    padding: 0 clamp(18px, 4vw, 40px);
}

.marquee-track {
    animation: marquee-scroll 28s linear infinite;
    display: flex;
    gap: 18px;
    width: max-content;
}

.client-marquee:hover .marquee-track {
    animation-play-state: paused;
}

.marquee-track span {
    align-items: center;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 6px;
    color: #fff;
    display: inline-flex;
    font-weight: 700;
    height: 78px;
    min-width: 210px;
    justify-content: center;
    padding: 10px 24px;
    white-space: nowrap;
}

.marquee-track img {
    max-height: 52px;
    max-width: 180px;
    object-fit: contain;
}

.client-marquee.is-logo-cloud {
    padding: 36px clamp(18px, 4vw, 40px) 30px;
}

.client-marquee.is-logo-cloud .marquee-title {
    padding: 0;
}

.client-marquee.is-logo-cloud .marquee-viewport {
    max-width: 1180px;
    padding: 0;
}

.client-marquee.is-logo-cloud .marquee-track {
    animation: none;
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 220px));
    justify-content: center;
    margin: 0 auto;
    width: 100%;
}

.client-marquee.is-logo-cloud .marquee-track span {
    box-shadow: none;
    min-width: 0;
    width: 100%;
}

@keyframes marquee-scroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

.content-band {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.privacy-content {
    display: grid;
    gap: 16px;
    margin: 0 auto;
    max-width: 980px;
    padding: 0 clamp(18px, 4vw, 40px) 64px;
}

.privacy-content article {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 22px;
}

.privacy-content p {
    color: var(--muted);
    margin-bottom: 0;
}

.proof-strip {
    grid-template-columns: 1.1fr 1fr 1fr;
    padding-bottom: 28px;
}

.proof-strip div {
    border-left: 3px solid var(--primary);
    padding: 8px 0 8px 16px;
}

.proof-strip strong {
    display: block;
    font-size: 1.6rem;
    line-height: 1.1;
}

.proof-strip span {
    color: var(--muted);
    display: block;
    margin-top: 6px;
}

.hero {
    background:
        linear-gradient(90deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.58) 48%, rgba(15, 23, 42, 0.2)),
        url("../img/hero-calibracao.d083168581e0.jpg") center / cover;
    color: #fff;
    max-width: none;
    min-height: clamp(520px, calc(100vh - 140px), 640px);
    padding: clamp(60px, 9vw, 112px) clamp(18px, 5vw, 72px) clamp(34px, 6vw, 70px);
}

.hero-content {
    display: grid;
    gap: clamp(28px, 6vw, 80px);
    grid-template-columns: minmax(0, 760px) minmax(220px, 360px);
    margin: 0 auto;
    max-width: 1180px;
    width: 100%;
}

.hero-copy {
    align-self: center;
}

.hero .eyebrow {
    color: #99f6e4;
}

.hero h1 {
    color: #fff;
    font-size: clamp(2.6rem, 5.4vw, 5.4rem);
    max-width: 820px;
}

.hero p {
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(1rem, 1.5vw, 1.28rem);
    max-width: 720px;
}

.hero .edit-pencil {
    background: rgba(255, 255, 255, 0.96);
}

.hero .editable-text.is-editing [data-editable-display] {
    background: rgba(15, 23, 42, 0.82);
    box-shadow: 0 0 0 2px #99f6e4;
}

.hero-secondary {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.45) !important;
    color: #fff !important;
}

.process-flow {
    align-self: end;
    display: grid;
    gap: 10px;
}

.process-flow span {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 6px;
    color: #fff;
    font-weight: 700;
    padding: 12px 14px;
}

.proof-strip {
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    grid-template-columns: 0.85fr 1fr 1fr;
    max-width: none;
    padding: 34px clamp(18px, 5vw, 72px);
}

.proof-strip > div {
    border-left: 4px solid var(--primary);
    margin: 0 auto;
    max-width: 340px;
    width: 100%;
}

.proof-strip h2 {
    font-size: 1.6rem;
    line-height: 1.12;
    margin-bottom: 4px;
}

.service-showcase,
.institution-hero,
.operation-band,
.calibration-scope,
.valve-feature,
.narrative-band,
.home-services,
.equipment-story,
.story-section,
.wide-image-band,
.standards-feature,
.photo-gallery-section,
.identity-band,
.field-experience,
.final-cta {
    margin: 0 auto;
    max-width: 1180px;
    padding: clamp(42px, 6vw, 76px) clamp(18px, 4vw, 40px);
}

.service-showcase {
    display: grid;
    gap: clamp(28px, 5vw, 54px);
}

.service-panel {
    align-items: center;
    display: grid;
    gap: clamp(24px, 5vw, 54px);
    grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
}

.service-panel.image-left {
    grid-template-columns: minmax(320px, 1.1fr) minmax(0, 0.9fr);
}

.service-panel h2,
.institution-hero h1,
.section-heading h2,
.valve-feature h2 {
    color: var(--text);
}

.service-panel h2,
.section-heading h2,
.valve-feature h2 {
    font-size: clamp(1.8rem, 3.5vw, 3rem);
    line-height: 1.08;
}

.service-panel p,
.institution-hero p,
.operation-band p,
.calibration-scope li,
.valve-feature p {
    color: var(--muted);
    font-size: 1.02rem;
}

.service-panel figure,
.institution-media,
.institution-visual,
.valve-feature figure {
    margin: 0;
}

.service-panel img,
.institution-media img,
.valve-feature img {
    border-radius: 8px;
    box-shadow: var(--shadow);
    display: block;
    height: 100%;
    object-fit: cover;
    width: 100%;
}

.service-panel figure {
    aspect-ratio: 4 / 3;
}

.narrative-band,
.institution-hero {
    align-items: center;
    display: grid;
    gap: clamp(28px, 6vw, 72px);
    grid-template-columns: minmax(0, 0.95fr) minmax(360px, 1.05fr);
}

.institution-hero {
    background: #f4f8fa;
    border-bottom: 1px solid var(--line);
    max-width: none;
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
}

.institution-hero h1 {
    max-width: 820px;
}

.institution-visual img,
.narrative-band img,
.wide-image-band > img,
.standards-feature img,
.identity-images img,
.equipment-gallery img {
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 8px;
    display: block;
    object-fit: contain;
    width: 100%;
}

.institution-visual img {
    box-shadow: var(--shadow-strong);
    max-height: 560px;
}

.institution-visual figcaption,
.equipment-gallery figcaption {
    color: var(--muted);
    font-size: 0.9rem;
    margin-top: 10px;
}

.institution-visual figcaption {
    border-left: 3px solid var(--primary);
    padding-left: 12px;
}

.narrative-band {
    padding-bottom: 52px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    border-top: 1px solid var(--line);
    justify-content: center;
    max-width: none;
}

.narrative-band figure {
    margin: 0;
}

.narrative-band img {
    box-shadow: var(--shadow-strong);
    height: clamp(300px, 32vw, 430px);
    object-fit: cover;
}

.narrative-band > div {
    max-width: 560px;
}

.narrative-band h2 {
    font-size: clamp(1.8rem, 3vw, 2.7rem);
    line-height: 1.08;
    margin-bottom: 16px;
}

.narrative-band p {
    color: var(--muted);
    font-size: 1.02rem;
}

.institution-media {
    display: grid;
    gap: 16px;
    grid-template-columns: 1.2fr 0.8fr;
}

.institution-media img:first-child {
    aspect-ratio: 4 / 5;
}

.institution-media img:last-child {
    align-self: end;
    aspect-ratio: 4 / 3;
}

.operation-band {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding-top: 0;
}

.operation-band article,
.instrument-grid article,
.commitment-band > div {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 24px;
}

.operation-band span {
    color: var(--primary);
    display: block;
    font-weight: 800;
    margin-bottom: 20px;
}

.operation-band h2,
.instrument-grid h3 {
    font-size: 1.22rem;
    line-height: 1.18;
}

.story-section {
    background: #edf4f2;
    border-block: 1px solid var(--line);
    max-width: none;
    overflow: hidden;
    padding-bottom: clamp(34px, 5vw, 56px);
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-top: clamp(34px, 5vw, 56px);
}

.story-section .section-heading,
.calibration-scope .section-heading {
    border-left: 4px solid var(--primary);
    padding-left: 18px;
}

.timeline-grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-top: 24px;
    position: relative;
}

.timeline-grid::before {
    background: linear-gradient(90deg, transparent, rgba(15, 118, 110, 0.45), transparent);
    content: "";
    height: 2px;
    left: 24px;
    position: absolute;
    right: 24px;
    top: 38px;
}

.timeline-grid article {
    background: linear-gradient(180deg, #ffffff, #f8fafc);
    border: 1px solid var(--line);
    border-top: 4px solid var(--primary);
    border-radius: 8px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
    padding: 20px;
    position: relative;
    z-index: 1;
}

.timeline-grid span {
    color: var(--primary);
    display: block;
    font-weight: 800;
    margin-bottom: 18px;
}

.timeline-grid h3 {
    font-size: 1.05rem;
    margin-bottom: 10px;
}

.timeline-grid p {
    color: var(--muted);
    font-size: 0.95rem;
}

.wide-image-band,
.standards-feature,
.identity-band {
    align-items: center;
    display: grid;
    gap: clamp(24px, 5vw, 58px);
    grid-template-columns: minmax(360px, 1.05fr) minmax(0, 0.95fr);
}

.wide-image-band {
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    max-width: none;
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
}

.wide-image-band > div,
.standards-feature > div,
.valve-feature > div,
.identity-band > div:first-child,
.experience-copy {
    border-left: 4px solid var(--primary);
    padding-left: 22px;
}

.home-services {
    background: #111827;
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: none;
}

.home-services article {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 8px;
    color: #fff;
    padding: clamp(24px, 4vw, 36px);
}

.home-services article:first-child {
    margin-left: auto;
    max-width: 570px;
    width: 100%;
}

.home-services article:last-child {
    margin-right: auto;
    max-width: 570px;
    width: 100%;
}

.home-services span {
    color: #99f6e4;
    display: block;
    font-weight: 800;
    margin-bottom: 18px;
}

.home-services h2 {
    color: #fff;
    font-size: clamp(1.5rem, 2.5vw, 2.2rem);
    line-height: 1.1;
}

.home-services p {
    color: rgba(255, 255, 255, 0.76);
}

.home-services .edit-pencil {
    background: #fff;
}

.home-services .editable-text.is-editing [data-editable-display] {
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 2px #99f6e4;
    color: #fff;
}

.wide-image-band > img,
.standards-feature img {
    box-shadow: var(--shadow-strong);
    max-height: 620px;
}

.wide-image-band h2,
.standards-feature h2,
.identity-band h2,
.field-experience h2,
.final-cta h2 {
    font-size: clamp(1.8rem, 3.5vw, 3rem);
    line-height: 1.08;
}

.wide-image-band p,
.standards-feature p,
.identity-band p,
.field-experience p,
.final-cta p {
    color: var(--muted);
    font-size: 1.02rem;
}

.calibration-scope {
    background:
        linear-gradient(135deg, rgba(15, 118, 110, 0.14), transparent 34%),
        #111827;
    color: #fff;
    max-width: none;
    padding-bottom: clamp(46px, 5vw, 64px);
    padding-top: clamp(46px, 5vw, 64px);
}

.calibration-scope > * {
    margin-left: auto;
    margin-right: auto;
    max-width: 1180px;
}

.calibration-scope .eyebrow {
    color: #99f6e4;
}

.calibration-scope h2,
.calibration-scope h3 {
    color: #fff;
}

.instrument-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 24px;
}

.instrument-grid article {
    background: rgba(255, 255, 255, 0.09);
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: none;
}

.instrument-grid ul {
    margin: 0;
    padding-left: 18px;
}

.instrument-grid li {
    color: rgba(255, 255, 255, 0.78);
    margin: 0 0 8px;
}

.valve-feature {
    align-items: center;
    background: #f7faf9;
    border-bottom: 1px solid var(--line);
    border-top: 1px solid var(--line);
    display: grid;
    gap: clamp(24px, 5vw, 58px);
    grid-template-columns: minmax(320px, 1.05fr) minmax(0, 0.95fr);
    max-width: none;
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
}

.valve-feature figure {
    aspect-ratio: 16 / 10;
}

.equipment-story,
.photo-gallery-section {
    padding-top: 0;
}

.equipment-gallery {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 24px;
}

.equipment-gallery figure {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
    margin: 0;
    padding: 12px;
}

.equipment-gallery img {
    height: clamp(220px, 24vw, 320px);
}

.large-gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.large-gallery img {
    height: clamp(260px, 30vw, 380px);
}

.identity-band {
    background: #eef6f4;
    border-block: 1px solid var(--line);
    max-width: none;
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
}

.identity-band > * {
    margin-left: 0;
    margin-right: 0;
    max-width: none;
}

.identity-images {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.identity-images.single-image {
    grid-template-columns: 1fr;
}

.identity-images img {
    box-shadow: var(--shadow);
    height: clamp(280px, 32vw, 460px);
}

.field-experience {
    align-items: center;
    background: #f7f9fb;
    border-top: 1px solid var(--line);
    display: grid;
    gap: clamp(28px, 5vw, 70px);
    grid-template-columns: minmax(0, 1fr) minmax(300px, 0.78fr);
    max-width: none;
    padding-bottom: 48px;
    padding-left: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
    padding-right: max(clamp(18px, 4vw, 40px), calc((100vw - 1180px) / 2 + 40px));
}

.field-experience > div {
    max-width: none;
}

.experience-copy {
    max-width: 680px !important;
}

.experience-highlights {
    display: grid;
    gap: 12px;
}

.experience-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-left: 4px solid var(--primary);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 20px;
}

.experience-card h2 {
    font-size: 1.05rem;
    line-height: 1.2;
    margin-bottom: 8px;
}

.experience-card p {
    font-size: 0.98rem;
    margin-bottom: 0;
}

.accent-card {
    background: #111827;
    border-color: #111827;
    border-left-color: #99f6e4;
    color: #fff;
}

.accent-card h2 {
    color: #fff;
}

.accent-card p {
    color: rgba(255, 255, 255, 0.76);
}

.final-cta {
    background: #111827;
    color: #fff;
    max-width: none;
    text-align: center;
}

.final-cta h2 {
    color: #fff;
}

.final-cta p {
    color: rgba(255, 255, 255, 0.76);
    margin-left: auto;
    margin-right: auto;
    max-width: 720px;
}

.final-cta .eyebrow {
    color: #99f6e4;
}

.commitment-band {
    padding-top: 0;
}

.compact {
    padding-bottom: 24px;
}

.auth-page {
    display: grid;
    min-height: 620px;
    place-items: center;
}

.auth-panel {
    max-width: 420px;
    width: 100%;
}

label {
    color: var(--text);
    display: block;
    font-size: 0.92rem;
    font-weight: 700;
    margin-bottom: 6px;
}

input,
select,
textarea {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 6px;
    color: var(--text);
    font: inherit;
    margin-bottom: 16px;
    min-height: 42px;
    padding: 9px 10px;
    width: 100%;
}

.workspace-heading,
.detail-heading,
.detail-actions {
    align-items: flex-start;
    display: flex;
    gap: 18px;
    justify-content: space-between;
    margin-bottom: 24px;
}

.detail-actions {
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    margin-bottom: 0;
}

.metrics {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    padding-bottom: 20px;
}

.metrics div {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px;
}

.metrics strong {
    display: block;
    font-size: 1.8rem;
}

.metrics span {
    color: var(--muted);
}

.support-documents {
    align-items: center;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: flex;
    gap: 18px;
    justify-content: space-between;
    margin: 0 auto 24px;
    max-width: 1180px;
    padding: 16px 18px;
}

.certificates-workspace .metrics,
.certificates-workspace .step-dashboard,
.certificates-workspace .support-documents,
.certificates-workspace .selected-context,
.certificates-workspace .duplicate-alert,
.certificates-workspace .filters,
.certificates-workspace .table-wrap {
    max-width: 100%;
}

.support-documents h2 {
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.support-documents p {
    color: var(--muted);
    margin-bottom: 0;
}

.support-documents-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.compact-actions {
    margin-top: 12px;
}

.step-dashboard {
    margin: 0 auto 18px;
    max-width: 1180px;
}

.step-dashboard h2 {
    margin-bottom: 12px;
}

.selected-context {
    align-items: center;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: flex;
    gap: 14px;
    justify-content: space-between;
    margin: 0 auto 18px;
    max-width: 1180px;
    padding: 14px 18px;
}

.selected-context strong,
.selected-context span {
    display: block;
}

.selected-context span {
    color: var(--muted);
    margin-top: 2px;
}

.duplicate-alert {
    background: #fffbeb;
    border: 1px solid #fbbf24;
    border-radius: 8px;
    margin: 0 auto 18px;
    max-width: 1180px;
    padding: 16px 18px;
}

.duplicate-alert h2 {
    margin-bottom: 6px;
}

.duplicate-alert p {
    color: var(--warning);
    margin-bottom: 12px;
}

.duplicate-list {
    display: grid;
    gap: 10px;
}

.duplicate-list div {
    align-items: center;
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr 2fr auto;
}

.duplicate-list span {
    color: var(--muted);
}

.selection-grid {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.selection-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 96px;
    justify-content: center;
    padding: 18px;
    text-decoration: none;
}

.selection-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.selection-card span {
    color: var(--muted);
    margin-top: 4px;
}

.filters {
    align-items: end;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    grid-template-columns: 2fr 1fr 1fr auto auto;
    margin-bottom: 18px;
    padding-bottom: 16px;
    padding-top: 16px;
}

.filters input,
.filters select {
    margin-bottom: 0;
}

.table-wrap {
    overflow-x: auto;
}

.certificate-table-wrap {
    border: 1px solid var(--line);
    border-radius: 8px;
}

table {
    border-collapse: collapse;
    min-width: 920px;
    width: 100%;
}

.certificate-table {
    min-width: 1460px;
}

.certificate-table th,
.certificate-table td {
    white-space: nowrap;
}

.certificate-table td:nth-child(2),
.certificate-table td:nth-child(4) {
    min-width: 220px;
}

th,
td {
    border-bottom: 1px solid var(--line);
    padding: 14px 16px;
    text-align: left;
    vertical-align: middle;
}

th {
    background: var(--surface-muted);
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
}

.actions a {
    color: var(--accent);
    font-weight: 700;
    text-decoration: none;
}

.actions a.danger-action {
    color: var(--danger);
}

.empty {
    color: var(--muted);
    text-align: center;
}

.status {
    border-radius: 999px;
    display: inline-flex;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 4px 10px;
    white-space: nowrap;
}

.status.vigente {
    background: #dcfce7;
    color: var(--success);
}

.status.a_vencer {
    background: #fef3c7;
    color: var(--warning);
}

.status.vencido {
    background: #fee4e2;
    color: var(--danger);
}

.status.criado,
.status.atualizado {
    background: #dcfce7;
    color: var(--success);
    text-transform: capitalize;
}

.status.erro {
    background: #fee4e2;
    color: var(--danger);
    text-transform: capitalize;
}

.status.ok,
.status.atencao {
    text-transform: capitalize;
}

.status.ok {
    background: #dcfce7;
    color: var(--success);
}

.status.atencao {
    background: #fef3c7;
    color: var(--warning);
}

.bulk-results {
    margin-top: 24px;
}

.upload-prerequisite {
    align-items: flex-start;
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
    margin-top: 16px;
}

.upload-prerequisite-list {
    display: grid;
    gap: 6px;
    list-style: none;
    margin: 4px 0 0;
    padding: 0;
    width: 100%;
}

.upload-prerequisite-list li {
    align-items: center;
    display: flex;
    gap: 12px;
    justify-content: space-between;
}

.upload-prerequisite-list a {
    color: var(--accent);
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.bulk-preview {
    margin-top: 24px;
}

.bulk-preview .workspace-heading {
    margin: 0 auto 16px;
    max-width: 1180px;
}

.bulk-preview .table-wrap {
    margin: 0 auto;
    max-width: 1180px;
}

.bulk-confirm-footer {
    display: flex;
    justify-content: flex-end;
    margin: 16px auto 0;
    max-width: 1180px;
}

.management-section,
.upload-mode-tabs,
.selected-files-panel {
    margin-top: 24px;
}

.section-title-row {
    align-items: center;
    display: flex;
    gap: 14px;
    justify-content: space-between;
    margin-bottom: 12px;
}

.section-title-row h2 {
    margin-bottom: 0;
}

.upload-mode-tabs {
    display: flex;
    gap: 10px;
    margin-left: auto;
    margin-right: auto;
    max-width: 760px;
}

.upload-panel.is-hidden {
    display: none;
}

.current-file {
    background: var(--surface-muted);
    border: 1px solid var(--line);
    border-radius: 8px;
    display: flex;
    gap: 10px;
    justify-content: space-between;
    margin-bottom: 16px;
    padding: 12px 14px;
}

.current-file a {
    color: var(--accent);
    font-weight: 700;
    text-decoration: none;
}

.table-logo {
    display: block;
    max-height: 34px;
    max-width: 120px;
    object-fit: contain;
}

.selected-files-panel {
    background: var(--surface-muted);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
}

.selected-files-panel h2 {
    margin-bottom: 12px;
}

.selected-files-panel ul {
    display: grid;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.selected-files-panel li {
    align-items: center;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
    display: flex;
    gap: 12px;
    justify-content: space-between;
    padding: 10px 12px;
}

.selected-files-panel small {
    color: var(--muted);
    display: block;
}

.selected-files-panel button {
    background: transparent;
    border: 0;
    color: var(--danger);
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.selected-files-overflow {
    color: var(--muted);
    font-weight: 700;
    justify-content: center !important;
}

.detail-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding-bottom: 0;
    padding-top: 0;
}

.detail-grid div {
    padding: 20px;
}

dt {
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
}

dd {
    margin: 6px 0 0;
}

.notes {
    margin-top: 18px;
}

.back-link {
    color: var(--accent);
    display: inline-flex;
    font-weight: 700;
    margin-top: 18px;
    text-decoration: none;
}

.data-form {
    max-width: 760px;
}

[data-field="unidades_permitidas"] label {
    align-items: center;
    display: flex;
    gap: 10px;
    padding: 6px 0;
}

[data-field="unidades_permitidas"] input[type="checkbox"] {
    margin: 0;
    min-height: auto;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.field ul,
.errorlist {
    color: var(--danger);
    margin: -10px 0 14px;
    padding-left: 18px;
}

.messages {
    margin: 18px auto 0;
    max-width: 1180px;
    padding: 0 clamp(18px, 4vw, 40px);
}

.message {
    border-radius: 8px;
    padding: 12px 14px;
}

.message-success {
    background: #dcfce7;
    color: var(--success);
}

.message-warning {
    background: #fef3c7;
    color: var(--warning);
}

.message-info {
    background: #e0f2fe;
    color: #075985;
    margin-bottom: 18px;
}

.message-error {
    background: #fee4e2;
    color: var(--danger);
    margin-bottom: 16px;
}

.danger-button {
    background: var(--danger) !important;
}

.impact-list {
    margin: 8px 0 0;
    padding-left: 18px;
}

.pagination {
    justify-content: center;
    margin-top: 20px;
}

.pagination a {
    color: var(--accent);
    font-weight: 700;
    text-decoration: none;
}

.site-footer {
    align-items: flex-start;
    background: #171717;
    border-top: 1px solid var(--line);
    color: #e5e5e5;
    display: grid;
    gap: 28px;
    grid-template-columns: minmax(240px, 1.4fr) minmax(170px, 1fr) minmax(220px, 1fr) minmax(190px, 0.8fr);
    justify-content: stretch;
}

.site-footer > div {
    min-width: 0;
}

.site-footer .brand-mark {
    background: #fff;
    color: #171717;
    display: inline-flex;
    margin-right: 8px;
    width: auto;
}

.site-footer strong,
.site-footer span,
.site-footer a,
.site-footer p {
    display: block;
}

.site-footer strong {
    color: #fff;
    margin-bottom: 8px;
}

.site-footer span,
.site-footer a,
.site-footer p {
    color: #d4d4d4;
    margin: 0 0 6px;
    text-decoration: none;
}

.site-footer a:hover {
    color: #fff;
}

.footer-links {
    align-items: flex-start;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.footer-links a {
    margin-bottom: 0;
}

.site-footer .footer-privacy-button {
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 6px;
    color: #fff;
    display: inline-flex;
    font-weight: 700;
    justify-content: center;
    margin-top: 4px;
    min-height: 38px;
    padding: 8px 12px;
}

.site-footer .footer-privacy-button:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.developer-credit {
    color: #a3a3a3 !important;
    font-size: 0.78rem;
    margin-top: 12px !important;
}

.footer-brand p {
    margin-top: 10px;
    max-width: 340px;
}

.footer-editable .edit-pencil {
    background: #fff;
    color: var(--text);
    right: -30px;
}

.footer-editable.is-editing [data-editable-display] {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

@media (max-width: 860px) {
    .site-header,
    .workspace-heading,
    .detail-heading,
    .selected-context {
        align-items: center;
        flex-direction: column;
    }

    .selected-context {
        align-items: stretch;
    }

    .site-header {
        display: flex;
    }

    .site-nav {
        justify-content: center;
    }

    .section-grid,
    .company-summary,
    .proof-strip,
    .content-band,
    .hero-content,
    .service-panel,
    .service-panel.image-left,
    .institution-hero,
    .operation-band,
    .instrument-grid,
    .valve-feature,
    .narrative-band,
    .home-services,
    .timeline-grid,
    .wide-image-band,
    .standards-feature,
    .equipment-gallery,
    .large-gallery,
    .identity-band,
    .identity-images,
    .field-experience,
    .metrics,
    .selection-grid,
    .filters,
    .detail-grid,
    .duplicate-list div,
    .site-footer {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
        padding-bottom: 42px;
        padding-top: 72px;
    }

    .hero h1 {
        font-size: clamp(2.3rem, 12vw, 3.7rem);
    }

    .process-flow {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .proof-strip > div {
        max-width: none;
    }

    .service-panel figure,
    .institution-media,
    .institution-visual img,
    .wide-image-band > img,
    .standards-feature img,
    .equipment-gallery img,
    .identity-images img,
    .valve-feature figure {
        min-height: 260px;
    }

    .institution-media {
        grid-template-columns: 1fr;
    }

    .home-services article:first-child,
    .home-services article:last-child {
        margin-left: 0;
        margin-right: 0;
        max-width: none;
    }

    .hero-actions,
    .form-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .section-title-row {
        align-items: stretch;
        flex-direction: column;
    }

}
