@import url('https://fonts.googleapis.com/css2?family=Exo:wght@500;600;700;800&family=Fira+Sans:wght@400;500;600;700&display=swap');

:root {
    --ink: #0c1945;
    --muted: #68728a;
    --line: #dfe4ee;
    --surface: #ffffff;
    --soft: #f6f7fc;
    --primary: #0e5af2;
    --primary-dark: #0c1945;
    --primary-mid: #2a3761;
    --primary-soft: #eef2fb;
    --accent: #fec624;
    --success: #28a745;
    --shadow: 0 18px 48px rgba(12, 25, 69, .11);
}

* { box-sizing: border-box; }
html { background: var(--soft); }
body { margin: 0; color: var(--ink); background: var(--soft); font-family: "Fira Sans", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.5; }
.container { width: min(1140px, calc(100% - 40px)); margin: 0 auto; }
.topbar { background: #fff; border-top: 6px solid var(--primary-dark); border-bottom: 1px solid var(--line); box-shadow: 0 3px 13px rgba(12, 25, 69, .05); }
.nav-content { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { color: var(--ink); display: inline-flex; align-items: center; gap: 16px; text-decoration: none; }
.brand-logo { width: 180px; height: 50px; display: block; object-fit: contain; }
.brand-context { padding-left: 16px; color: var(--primary-mid); border-left: 1px solid #d6ddea; font-family: "Exo", "Fira Sans", sans-serif; font-size: 14px; font-weight: 700; letter-spacing: .025em; }
.nav-badge { padding: 7px 12px; color: var(--primary-dark); background: var(--primary-soft); border: 1px solid #d8e1fa; border-radius: 4px; font-family: "Exo", "Fira Sans", sans-serif; font-size: 11px; font-weight: 800; letter-spacing: .045em; text-transform: uppercase; }

.hero { overflow: hidden; position: relative; background: linear-gradient(118deg, #f6f8ff 0%, #fff 56%, #edf2ff 100%); border-bottom: 1px solid var(--line); }
.hero::before { position: absolute; top: 0; left: 0; width: 100%; height: 5px; content: ""; background: linear-gradient(90deg, var(--primary-dark), var(--primary), var(--accent)); }
.hero::after { position: absolute; right: -90px; bottom: -160px; width: 430px; height: 430px; content: ""; border: 70px solid rgba(14,90,242,.055); border-radius: 50%; }
.hero-grid { position: relative; z-index: 1; min-height: 510px; display: grid; grid-template-columns: 1.1fr .9fr; gap: 76px; align-items: center; padding: 68px 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; color: var(--primary); font-family: "Exo", "Fira Sans", sans-serif; font-size: 12px; font-weight: 800; letter-spacing: .085em; text-transform: uppercase; }
.status-dot { width: 8px; height: 8px; background: var(--success); border-radius: 50%; box-shadow: 0 0 0 4px rgba(40,167,69,.12); }
.hero h1 { max-width: 650px; margin: 14px 0 18px; font-size: clamp(38px, 4.2vw, 61px); line-height: 1.04; letter-spacing: -.055em; }
.hero h1, .section-intro h2, .page-heading h1, .download-head h2, .side-panel h2 { font-family: "Exo", "Fira Sans", sans-serif; }
.hero h1 em { color: var(--primary); font-style: normal; }
.hero p { max-width: 595px; margin: 0; color: #4b5f78; font-size: 18px; line-height: 1.7; }
.hero-points { display: flex; flex-wrap: wrap; gap: 12px 19px; margin-top: 28px; color: #41566f; font-size: 14px; font-weight: 650; }

.upload-card, .panel { background: var(--surface); border: 1px solid rgba(205,217,229,.9); border-radius: 19px; box-shadow: var(--shadow); }
.upload-card { padding: 30px; }
.card-heading { display: flex; align-items: center; gap: 13px; margin-bottom: 24px; }
.card-icon { width: 40px; height: 40px; display: grid; place-items: center; color: #fff; background: linear-gradient(145deg, var(--primary), #0844bc); border-radius: 10px; font-size: 24px; font-weight: 700; }
.card-heading h2 { margin: 0; font-size: 18px; letter-spacing: -.02em; }
.card-heading p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.upload-zone { min-height: 161px; padding: 22px; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; color: var(--muted); border: 1.5px dashed #afc2d2; border-radius: 13px; text-align: center; transition: .2s ease; }
.upload-zone:hover, .upload-zone.is-dragging { border-color: var(--primary); background: var(--primary-soft); }
.upload-zone.has-file { color: var(--primary-dark); border-style: solid; border-color: #a9bff4; background: var(--primary-soft); }
.upload-zone input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-symbol { margin-bottom: 5px; color: var(--primary); font-size: 33px; line-height: 1; transform: rotate(180deg); }
.upload-zone strong { max-width: 100%; overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.upload-zone span:last-child { margin-top: 4px; font-size: 12px; }
.field-group { margin: 21px 0; }
.field-group label { display: flex; justify-content: space-between; margin-bottom: 7px; font-size: 13px; font-weight: 750; }
.field-group label span { color: var(--muted); font-weight: 500; }
input[type="month"] { width: 100%; padding: 11px 12px; color: var(--ink); border: 1px solid #cbd7e2; border-radius: 9px; background: #fff; font: inherit; outline: none; }
input[type="month"]:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(23,109,101,.12); }
.field-group small { display: block; margin-top: 6px; color: var(--muted); font-size: 11px; line-height: 1.35; }
.button { min-height: 47px; padding: 0 19px; display: inline-flex; align-items: center; justify-content: center; gap: 20px; border: 0; border-radius: 10px; cursor: pointer; font: inherit; font-size: 14px; font-weight: 750; text-decoration: none; transition: .2s ease; }
.button-primary { color: #fff; background: var(--primary); box-shadow: 0 10px 20px rgba(14,90,242,.24); }
.button-primary:hover { background: #0844bc; transform: translateY(-1px); }
.button-secondary { color: var(--primary-dark); background: var(--primary-soft); }
.button-secondary:hover { background: #dfe7fb; }
.button-outline { color: var(--primary-dark); background: #fff; border: 1px solid #bcc9e6; }
.button-outline:hover { background: var(--primary-soft); }
.button-full { width: 100%; }
.button:disabled { cursor: wait; opacity: .7; transform: none; }

.capabilities { padding: 84px 0 70px; }
.section-intro { margin-bottom: 27px; }
.section-intro h2 { margin: 8px 0 0; font-size: 27px; letter-spacing: -.035em; }
.capability-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.capability-card { min-height: 202px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 13px; }
.record-code { display: inline-block; padding: 4px 8px; color: var(--primary-dark); background: #e8edfa; border-radius: 5px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; font-weight: 800; }
.capability-card h3 { margin: 18px 0 8px; font-size: 16px; letter-spacing: -.015em; }
.capability-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.process { margin-bottom: 76px; padding: 28px 34px; display: flex; align-items: center; justify-content: space-between; gap: 22px; background: linear-gradient(110deg, #0c1945 0%, #2a3761 65%, #0d3d8f 100%); border-radius: 16px; }
.process-step { display: flex; flex: 1; align-items: center; gap: 13px; color: #eaf4ff; }
.process-step span { color: var(--accent); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; font-weight: 800; }
.process-step p { max-width: 205px; margin: 0; font-size: 13px; line-height: 1.45; }
.process-line { width: 45px; height: 1px; background: #587086; }
.footer { padding: 23px 0; color: rgba(255,255,255,.72); background: #081530; border-top: 3px solid var(--accent); font-size: 12px; }
.footer .container { display: flex; justify-content: space-between; gap: 20px; }

/* Página de resultado */
.page-header { padding: 48px 0 28px; }
.breadcrumb { display: inline-flex; gap: 7px; align-items: center; margin-bottom: 14px; color: var(--muted); font-size: 12px; }
.breadcrumb a { color: var(--primary); text-decoration: none; }
.page-heading { display: flex; justify-content: space-between; align-items: end; gap: 22px; }
.page-heading h1 { max-width: 700px; margin: 7px 0 0; font-size: clamp(31px, 4vw, 46px); letter-spacing: -.05em; line-height: 1.08; }
.page-heading p { margin: 10px 0 0; color: var(--muted); }
.summary-grid { display: grid; grid-template-columns: 1.25fr .75fr .75fr .75fr; gap: 14px; margin: 0 0 25px; }
.summary-card { min-height: 118px; padding: 18px 20px; background: #fff; border: 1px solid var(--line); border-radius: 13px; }
.summary-card.primary { color: #fff; background: linear-gradient(135deg, #0c1945, #2a3761); border-color: var(--primary-dark); }
.summary-label { display: block; margin-bottom: 8px; color: var(--muted); font-size: 11px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.summary-card.primary .summary-label { color: #d6e2ff; }
.summary-value { display: block; overflow: hidden; font-size: 19px; font-weight: 760; letter-spacing: -.025em; text-overflow: ellipsis; white-space: nowrap; }
.summary-detail { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; }
.summary-card.primary .summary-detail { color: #dce7ff; }
.result-grid { display: grid; grid-template-columns: minmax(0, 1fr) 310px; align-items: start; gap: 22px; padding-bottom: 60px; }
.download-panel { padding: 8px; }
.download-head { padding: 17px 15px 13px; display: flex; justify-content: space-between; align-items: end; gap: 15px; }
.download-head h2, .side-panel h2 { margin: 0; font-size: 17px; letter-spacing: -.02em; }
.download-head p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.file-list { list-style: none; margin: 0; padding: 0; }
.file-item { display: flex; align-items: center; gap: 13px; padding: 16px 15px; border-top: 1px solid #e7edf3; }
.file-icon { width: 37px; height: 42px; flex: 0 0 auto; display: grid; place-items: center; color: var(--primary-dark); background: #e8edfa; border-radius: 8px; font-family: ui-monospace, monospace; font-size: 11px; font-weight: 800; }
.file-info { min-width: 0; flex: 1; }
.file-info strong { display: block; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.file-info span { display: block; margin-top: 2px; color: var(--muted); font-size: 12px; }
.button-download { min-height: 35px; padding: 0 12px; font-size: 12px; }
.file-preview { width: 100%; margin-top: 10px; overflow: hidden; border: 1px solid #e2e9f0; border-radius: 9px; }
.file-preview summary { padding: 9px 11px; cursor: pointer; color: var(--primary-dark); background: #f8fbfd; font-size: 11px; font-weight: 700; }
.table-scroll { overflow-x: auto; }
.file-preview table { min-width: 650px; border-collapse: collapse; font-size: 10px; }
.file-preview th { color: #53677e; background: #f2f6f9; font-weight: 750; text-align: left; }
.file-preview th, .file-preview td { max-width: 150px; padding: 7px 9px; overflow: hidden; border-top: 1px solid #e7edf3; text-overflow: ellipsis; white-space: nowrap; }
.file-preview td { color: #506178; }
.side-stack { display: grid; gap: 15px; }
.side-panel { padding: 22px; }
.side-panel p { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.detail-list { margin: 16px 0 0; padding: 0; list-style: none; }
.detail-list li { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-top: 1px solid #e8eef4; color: #53657c; font-size: 12px; }
.detail-list li strong { color: var(--ink); font-weight: 750; text-align: right; }
.notice { padding: 15px 17px; border: 1px solid; border-radius: 11px; font-size: 13px; line-height: 1.5; }
.notice strong { display: block; margin-bottom: 2px; }
.notice-warning { color: #7c4c0d; background: #fff7e9; border-color: #f4d8a4; }
.notice-error { color: #8a2534; background: #fff1f3; border-color: #efc0c8; }
.empty-panel { padding: 34px; text-align: center; }
.empty-panel h2 { margin: 0 0 8px; font-size: 19px; }
.empty-panel p { margin: 0 0 21px; color: var(--muted); font-size: 14px; }

/* Auditoria guiada do Bloco K */
.status-dot.warning { background: #e29a15; box-shadow: 0 0 0 4px rgba(226,154,21,.14); }
.audit-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; align-items: start; gap: 24px; padding-bottom: 64px; }
.audit-main { display: grid; gap: 15px; }
.audit-form { overflow: hidden; padding: 0 0 24px; background: #fbfcff; }
.audit-form-head { display: flex; align-items: start; justify-content: space-between; gap: 18px; padding: 28px 28px 25px; background: linear-gradient(112deg, #f2f6ff 0%, #fff 78%); border-bottom: 1px solid #dce5f4; }
.audit-form h2, .guide-panel h2 { margin: 6px 0 5px; font-family: "Exo", "Fira Sans", sans-serif; font-size: 23px; letter-spacing: -.035em; }
.audit-form-head p, .audit-units > p { max-width: 600px; margin: 0; color: var(--muted); font-size: 13px; }
.audit-item { min-height: 154px; display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 24px; margin: 17px 20px 0; padding: 21px; background: #fff; border: 1px solid #dbe4f1; border-left: 4px solid var(--primary); border-radius: 12px; box-shadow: 0 8px 19px rgba(12,25,69,.045); }
.audit-item-head { display: flex; flex-direction: column; align-items: start; gap: 9px; padding-right: 20px; border-right: 1px solid #e5ebf3; }
.audit-item h3 { margin: 0; font-family: "Exo", "Fira Sans", sans-serif; font-size: 18px; letter-spacing: -.025em; }
.audit-item p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.audit-missing { padding: 6px 8px; color: #a04120; background: #fff4ed; border: 1px solid #f2c8b4; border-radius: 5px; font-size: 11px; font-weight: 700; line-height: 1.35; }
.audit-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; gap: 12px 14px; }
.audit-fields label { display: grid; gap: 6px; color: #425875; font-size: 11px; font-weight: 800; letter-spacing: .01em; }
.audit-fields label:first-child { grid-column: 1 / -1; }
.audit-fields input, .audit-fields select { width: 100%; min-height: 41px; padding: 9px 11px; color: var(--ink); border: 1px solid #bfcede; border-radius: 8px; background: #fff; font: inherit; font-size: 13px; outline: none; transition: .18s ease; }
.audit-fields input::placeholder { color: #9aa9bc; }
.audit-fields input:focus, .audit-fields select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(14,90,242,.12); }
.audit-units { margin: 20px 20px 0; padding: 20px; background: #f2f6ff; border: 1px solid #d7e2f5; border-radius: 11px; }
.audit-units h3 { margin: 0 0 3px; font-family: "Exo", "Fira Sans", sans-serif; font-size: 16px; }
.audit-units .audit-fields { margin-top: 15px; grid-template-columns: repeat(2, minmax(150px, 1fr)); }
.audit-submit { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 22px 20px 0; padding: 20px; background: #0c1945; border-radius: 12px; }
.audit-submit p { max-width: 430px; margin: 0; color: #dce7ff; font-size: 12px; }
.audit-submit .button-primary { background: var(--accent); color: #16254d; box-shadow: none; }
.audit-submit .button-primary:hover { background: #ffd768; }
.audit-guide { display: grid; gap: 15px; }
.guide-panel { padding: 23px; background: #fff; }
.guide-steps { display: grid; gap: 16px; margin: 20px 0 0; padding: 0; list-style: none; counter-reset: guide; }
.guide-steps li { position: relative; min-height: 42px; padding-left: 40px; counter-increment: guide; }
.guide-steps li::before { position: absolute; top: 0; left: 0; width: 26px; height: 26px; display: grid; place-items: center; color: var(--primary-dark); background: #e8edfa; border-radius: 50%; content: counter(guide); font-family: ui-monospace, monospace; font-size: 11px; font-weight: 800; }
.guide-steps strong, .guide-steps span { display: block; }
.guide-steps strong { font-size: 13px; }
.guide-steps span { margin-top: 2px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.guide-steps code { padding: 1px 3px; color: var(--primary-dark); background: #eef2fb; border-radius: 3px; font-size: 10px; }

@media (max-width: 860px) {
    .hero-grid { grid-template-columns: 1fr; gap: 35px; padding: 53px 0; }
    .hero-copy { max-width: 650px; }
    .upload-card { max-width: 580px; }
    .capability-grid { grid-template-columns: repeat(2, 1fr); }
    .summary-grid { grid-template-columns: repeat(2, 1fr); }
    .result-grid { grid-template-columns: 1fr; }
    .audit-layout { grid-template-columns: 1fr; }
    .side-stack { grid-template-columns: repeat(2, 1fr); }
    .audit-guide { grid-template-columns: repeat(2, 1fr); }
    .audit-guide .notice { grid-column: 1 / -1; }
    .audit-fields { grid-template-columns: repeat(2, minmax(160px, 1fr)); }
}
@media (max-width: 580px) {
    .container { width: min(100% - 28px, 1140px); }
    .nav-badge, .brand-context { display: none; }
    .brand-logo { width: 155px; height: 43px; }
    .hero-grid { padding: 42px 0; }
    .hero h1 { font-size: 38px; }
    .hero p { font-size: 16px; }
    .upload-card { padding: 22px; }
    .capabilities { padding: 56px 0 45px; }
    .capability-grid, .summary-grid, .side-stack, .audit-guide, .audit-fields, .audit-units .audit-fields { grid-template-columns: 1fr; }
    .process { display: grid; padding: 24px; }
    .process-line { width: 1px; height: 24px; margin-left: 5px; }
    .footer .container, .page-heading { align-items: start; flex-direction: column; }
    .page-header { padding-top: 34px; }
    .file-item { flex-wrap: wrap; }
    .file-info { min-width: calc(100% - 54px); }
    .file-item > .button { width: 100%; }
    .audit-form { padding: 20px; }
    .audit-form-head, .audit-item-head, .audit-submit { align-items: start; flex-direction: column; }
    .audit-item { grid-template-columns: 1fr; gap: 16px; margin: 15px 0 0; padding: 18px; }
    .audit-item-head { padding: 0 0 14px; border-right: 0; border-bottom: 1px solid #e5ebf3; }
    .audit-units, .audit-submit { margin-left: 0; margin-right: 0; }
    .audit-missing { max-width: none; text-align: left; }
}
