:root {
  --color-primary: #104dcf;
  --color-primary-dark: #0D47A1;
  --color-primary-light: #166ae9;
  --color-dark: #000;
  --color-light-bg: #fafafa;
  --color-alt-bg: #f2f5f9;
  --color-border: #e2e6eb;
  --radius: 8px;
  --max-width: 1200px;
  font-family: "Inter", "Roboto", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--color-dark);
  line-height: 1.5;
  background: #f6f8fb;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

section {
  position: relative;
}

section h1 {
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

h1,
h2,
h3,
h4,
h5 {
  margin: 0 0 0.5em;
  font-weight: 500;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* =========================
   BADGES
========================= */

.badge {
  display: inline-block;
  background: var(--color-primary);
  color: #fff;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 1rem;
}

.badge-alt {
  background: var(--color-primary-dark);
}

/* =========================
   BOTÕES
========================= */

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.2s ease;
}

.btn:hover {
  text-decoration: none;
}

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

.btn-primary:hover {
  background: transparent;
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-outline {
  background: transparent;
  border-color: #fff;
  color: #fff;
}

.btn-outline:hover {
  background: #fff;
  color: var(--color-dark);
}

.btn-light {
  background: #fff;
  color: var(--color-dark);
}

.btn-small {
  padding: 6px 16px;
  font-size: 0.85rem;
}

.link-underline {
  border-bottom: 1px solid currentColor;
}

/* =========================
   TOPBAR
========================= */

.topbar {
  background: var(--color-primary-dark);
  color: #fff;
  padding: 15px 0;
  font-size: 0.8125rem;
}

.topbar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0px 24px;
  display: flex;
  gap: 30px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.topbar a {
  color: #fff;
}

.topbar .icon {
  font-style: normal;
}

.social {

  display: flex;
  gap: 12px;
}

/* =========================
   HEADER / MENU
========================= */

.main-header {
  background: #fff;
  border-bottom: 1px solid #eee;

  position: sticky;
  top: 0;

  z-index: 100;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;

  padding: 14px 20px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.logo img {
  height: 50px;
}

.menu-toggle {
  display: none;
  width: 48px;
  height: 48px;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: 50%;
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-primary-dark);
  border-radius: 999px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle.is-active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.is-active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.menu-backdrop,
.menu-panel-top,
.mobile-label,
.menu-contact {
  display: none;
}

.menu-toggle:focus-visible,
.menu-close:focus-visible,
.main-nav a:focus-visible {
  outline: 3px solid #75c86a;
  outline-offset: 4px;
}

.menu-backdrop:focus-visible {
  outline: none;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: flex-end;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

.main-nav a {
  color: var(--color-dark);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: color 0.2s ease;
}

.main-nav a:hover {
  color: var(--color-primary);
  text-decoration: none;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 2px;
  background: var(--color-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.main-nav a:hover::after {
  transform: scaleX(1);
}

.main-nav .btn-primary {
  border-radius: 999px;
  padding: 12px 22px;
  color: #fff;
  background: linear-gradient(135deg, #3d9d2d 0%, #2e7d1f 100%);
  border-color: transparent;
  box-shadow: 0 8px 18px rgba(61, 157, 45, 0.25);
}

.main-nav .btn-primary:hover {
  background: #fff;
  color: #2e7d1f;
  border-color: #2e7d1f;
}

/* =========================
   HERO
========================= */

.hero {
  min-height: 520px;

  display: flex;
  align-items: center;

  background:
    linear-gradient(rgba(20, 30, 50, 0.68),
      rgba(20, 30, 50, 0.68)),
    url("https://jgsmetrologia.com.br/wp-content/uploads/2025/05/bg2.jpg") center / cover no-repeat;

  color: #fff;

  padding: 10px 20px;
}

.hero-inner {
  max-width: 700px;
  margin: 0 auto;
  text-align: left;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
}

.hero h2 {
  font-weight: 400;
  font-size: 1.25rem;
  margin-bottom: 1.5rem;
}

/* =========================
   GRIDS
========================= */

.grid-3,
.grid-2 {
  max-width: var(--max-width);
  margin: 0 auto;

  padding: 60px 20px;
  text-decoration: none;
  display: grid;
  gap: 30px;
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
  text-decoration: none;
}

.grid-2 {
  grid-template-columns: 1fr 1fr;
  align-items: center;
  text-decoration: none;
}

/* =========================
   QUICK CONTACT
========================= */

.quick-contact {
  background: var(--color-alt-bg);
  text-decoration: none;
  padding-top: 12px;
}

.card {
  background: #fff;
  padding: 30px;
  text-decoration: none;
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card h3 {
  color: var(--color-primary-dark);
  font-size: 1.5rem;
  margin-bottom: 0.85rem;
}

.card:hover {
  transform: translateY(-4px);
  text-decoration: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* =========================
   ACCREDITATION
========================= */

.accreditation .img-placeholder img {
  border-radius: var(--radius);
}

/* =========================
   CTA BAND
========================= */

.cta-band {
  background:
    var(--color-primary-dark) url("https://jgsmetrologia.com.br/wp-content/uploads/2025/05/b2-1.jpg") center / cover;

  background-blend-mode: multiply;

  color: #fff;

  text-align: center;

  padding: 60px 20px;
}

.cta-inner {
  max-width: 900px;
  margin: 0 auto;
}

.cta-band .badge {
  background: rgba(255, 255, 255, 0.15);
}

/* =========================
   CALIBRATION SCOPES
========================= */

.calibration {
  background: var(--color-light-bg);
  padding: 24px 0 10px;
}

.scope-card {
  background: #ffffff;
  padding: 26px 22px 20px;
  border-radius: var(--radius);
  text-align: center;
  border: 1px solid var(--color-border);
  box-shadow: 0 10px 22px rgba(15, 25, 40, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
}

.scope-card h3 {
  color: var(--color-primary-dark);
  font-size: 1.4rem;
  margin-bottom: 0.75rem;
}

.scope-card p {
  color: #3c4752;
  flex: 1;
  margin-bottom: 1.25rem;
}

.scope-card .btn-small {
  align-self: center;
  margin-top: auto;
}

.scope-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 34px rgba(7, 7, 7, 0.12);
}

/* =========================
   CONSULTING / ACCORDION
========================= */

.consulting {
  padding: 24px 0 20px;
}

.client-logos {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 24px;
}

.client-logos img {
  height: 42px;
  width: auto;
  opacity: 0.9;
  filter: grayscale(0.1);
}

.accordion {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 22px rgba(0,0,0,0.04);
  padding: 12px 18px;
}

.accordion details {
  border-bottom: 1px solid #e2e2e2;
  padding: 12px 0;
}

.accordion details:last-child {
  border-bottom: none;
}

.accordion summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--color-primary-dark);
  list-style: none;
}

.accordion summary::-webkit-details-marker {
  display: none;
}

.accordion ul {
  margin: 12px 0 0 18px;
  padding-left: 18px;
  color: #2d3748;
}

.accordion li {
  margin-bottom: 8px;
}

.about-audit {
  padding: 28px 0 48px;
}

.about-audit .grid-2 > div {
  padding: 10px 0;
}

/* =========================
   PROFICIENCY BAND
========================= */

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

.proficiency-inner {
  max-width: var(--max-width);

  margin: 0 auto;

  padding: 40px 20px;

  display: flex;

  justify-content: space-between;
  align-items: center;

  gap: 24px;

  flex-wrap: wrap;
}

/* =========================
   CONTACT
========================= */

.contact-info {
  display: flex;

  flex-direction: column;

  gap: 18px;
}

.contact-info p {
  margin: 0;
}

.contact-info a {
  color: #fff;
  font-weight: 600;
}

.footer {
  background: linear-gradient(180deg, #0f4ca8 0%, #0d3d8c 100%);
  color: #ffffff;
  margin-top: 0;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.contact-info a:hover {
  text-decoration: none;
  color: #ff4800;
}

/* =========================
   MAPA
========================= */

.map-wrap iframe {
  width: 100%;
  min-height: 350px;

  border-radius: var(--radius);

  border: 0;
}

/* =========================
   CONTACT FOOTER
========================= */

.contact-footer {
  background: var(--color-primary);

  color: #fff;

  padding: 60px 20px 20px;
}

.contact-footer .grid-2 {
  padding: 0 0 40px;
}

.contact-form-wrap form {
  display: flex;

  flex-direction: column;

  gap: 6px;
}

.contact-form-wrap input,
.contact-form-wrap textarea {
  padding: 10px;

  border-radius: var(--radius);

  border: none;

  margin-bottom: 12px;

  font-family: inherit;
}

.contact-form-wrap button {
  align-self: flex-start;
}

/* =========================
   FOOTER
========================= */

/* Área principal */

.footer-container {
  max-width: 1200px;

  margin: 0 auto;

  display: grid;

  grid-template-columns:
    1.5fr 1fr 1.5fr;

  gap: 70px;

  padding: 50px 20px 45px;
}

/* =========================
   LOGO DO FOOTER
========================= */

.footer-logo {
  width: 110px;

  height: auto;

  margin-bottom: 20px;
}

/* =========================
   TEXTO DA EMPRESA
========================= */

.footer-brand p {
  max-width: 390px;

  margin: 0;

  color: #ffffff;

  font-size: 15px;

  line-height: 1.55;
}

/* =========================
   TÍTULOS
========================= */

.footer h3 {
  margin: 0 0 20px;

  color: #ffffff;

  font-size: 18px;

  font-weight: 700;
}

/* =========================
   NAVEGAÇÃO
========================= */

.footer-navigation {
  display: flex;

  flex-direction: column;
}

.footer-navigation a {
  color: rgba(255, 255, 255, 0.88);

  text-decoration: none;

  font-size: 15px;

  margin-bottom: 12px;

  transition: 0.2s ease;
}

.footer-navigation a:hover {
  color: #ffffff;

  transform: translateX(3px);
}

/* =========================
   CONTATO DO FOOTER
========================= */

.footer-contact {
  display: flex;

  flex-direction: column;

  width: 100%;
}

.footer-contact p {
  display: flex;

  align-items: flex-start;

  gap: 10px;

  margin: 0 0 15px;

  color: rgba(255, 255, 255, 0.88);

  font-size: 15px;

  line-height: 1.5;
}

.footer-contact a {
  color: rgba(255, 255, 255, 0.88);

  text-decoration: none;

  word-break: break-word;
}

.footer-contact a:hover {
  color: #ffffff;

  text-decoration: underline;
}

/* =========================
   ÍCONES DO FOOTER
========================= */

.footer-icon {
  display: inline-flex;

  align-items: center;

  justify-content: center;

  flex-shrink: 0;

  width: 22px;

  min-width: 22px;

  height: 22px;

  color: #ffffff;
}

.footer-icon svg {
  display: block;

  width: 18px;

  height: 18px;

  fill: none;

  stroke: currentColor;

  stroke-width: 1.7;

  stroke-linecap: round;

  stroke-linejoin: round;
}

/* =========================
   PARTE INFERIOR
========================= */

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.25);
}

.footer-bottom-container {
  max-width: 1200px;

  margin: 0 auto;

  padding: 20px;
}

.footer-bottom p {
  margin: 0;

  color: #ffffff;

  font-size: 13px;
}

/* =========================
   RESPONSIVO
========================= */

@media (max-width: 800px) {

  .menu-toggle {
    display: inline-flex;
    z-index: 20;
  }

  .header-inner {
    flex-direction: row;
    gap: 18px;
    align-items: center;
  }

  .menu-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1000;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(14, 18, 16, 0.62);
    opacity: 0;
    visibility: hidden;
    cursor: pointer;
    transition: opacity 0.28s ease, visibility 0.28s ease;
  }

  .menu-backdrop.is-visible {
    opacity: 1;
    visibility: visible;
  }

  .main-nav {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: min(84vw, 430px);
    max-width: 430px;
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 18px 24px 28px;
    background: #171a18;
    color: #fff;
    box-shadow: -14px 0 38px rgba(0, 0, 0, 0.24);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.28s ease, visibility 0.28s ease;
  }

  .main-nav.is-open {
    transform: translateX(0);
    visibility: visible;
  }

  .menu-panel-top {
    display: flex;
    justify-content: flex-end;
    flex: 0 0 auto;
    margin-bottom: 24px;
  }

  .menu-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-size: 2rem;
    line-height: 1;
  }

  .menu-close:hover {
    background: rgba(255, 255, 255, 0.08);
  }

  .main-nav .client-access {
    display: block;
    flex: 0 0 auto;
    width: 100%;
    margin: 0 0 18px;
    padding: 16px 18px;
    border: 0;
    border-radius: 999px;
    background: #2e7d50;
    box-shadow: none;
    color: #fff;
    text-align: center;
    font-weight: 700;
  }

  .main-nav .client-access:hover {
    background: #37915d;
    color: #fff;
  }

  .desktop-label {
    display: none;
  }

  .main-nav .mobile-label {
    display: inline;
  }

  .main-nav ul {
    display: block;
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
  }

  .main-nav li {
    width: 100%;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .main-nav li:last-child {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .main-nav ul a {
    display: block;
    width: 100%;
    padding: 15px 0;
    color: #e5e8e5;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
  }

  .main-nav ul a:hover {
    color: #75c86a;
  }

  .main-nav ul a::after {
    display: none;
  }

  .menu-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: auto;
    padding-top: 28px;
  }

  .menu-contact a {
    color: #c5ccc6;
    font-size: 0.9rem;
    overflow-wrap: anywhere;
  }

  .menu-contact a:hover {
    color: #75c86a;
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .footer-container {
    grid-template-columns: 1fr;

    gap: 35px;

    padding: 40px 25px;
  }
}

html.menu-open {
  overflow: hidden;
}

@media (prefers-reduced-motion: reduce) {
  .menu-toggle span,
  .menu-backdrop,
  .main-nav {
    transition: none;
  }
}

@media (max-width: 768px) {

  .footer-brand p {
    max-width: 100%;
  }

  .footer-bottom-container {
    padding: 18px 25px;
  }

  .footer-bottom p {
    text-align: center;

    line-height: 1.5;
  }
}

@media (max-width: 500px) {

  .hero {
    min-height: 450px;

    padding: 60px 20px;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .hero h2 {
    font-size: 1.05rem;
  }

  .grid-3,
  .grid-2 {
    padding: 40px 20px;
  }

  .proficiency-inner {
    padding: 30px 20px;
  }

  .footer-bottom {
    flex-direction: column;
  }

  .footer-contact p {
    font-size: 14px;
  }
}

.footer-bottom {
  width: 100%;
  margin-top: 35px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-bottom-container {
  width: 100%;
  text-align: center;
}

.footer-bottom p {
  margin: 0;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.2px;
  color: rgba(255, 255, 255, 0.55);
}

@media (min-width: 801px) {
  .main-nav .client-access {
    color: #ffffff;
    background-color: #529927;
    padding: 10px 18px;
    border-radius: 999px;
    font-weight: 700;
  }

  .main-nav .client-access:hover {
    color: #529927;
    background-color: #fff;
    border-color: #529927;
  }
}