/* ============================================================
   MJ FREIOS — Design System
   Preto + laranja. Cantos arredondados.-industrial moderno.
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Sora:wght@400;500;600;700;800&family=Inter:wght@400;500;600;700&display=swap");

:root {
  /* Superfícies */
  --bg: #08090a;
  --bg-2: #0e1012;
  --surface: #141619;
  --surface-2: #1b1e22;
  --surface-3: #23272c;
  --line: #2a2e34;
  --line-soft: #1f2328;

  /* Fundos translucidos (header, cartao de vidro, barra flutuante) */
  --glass-1: rgba(8, 9, 10, 0.82);
  --glass-2: rgba(14, 16, 18, 0.92);
  --glass-3: rgba(20, 22, 25, 0.72);
  --glass-4: rgba(20, 22, 25, 0.92);
  --scrim: rgba(0, 0, 0, 0.72);

  /* Texto */
  --text: #f5f6f7;
  --text-2: #a8adb5;
  --text-3: #8b919b;

  /* Marca */
  --brand: #ff6b00;
  --brand-2: #ff8c1a;
  --brand-3: #e05600;
  --brand-ink: #120a04;
  --brand-soft: rgba(255, 107, 0, 0.12);
  --brand-soft-2: rgba(255, 107, 0, 0.22);

  /* Sinalização */
  --ok: #22c55e;
  --warn: #f59e0b;
  --info: #3b82f6;

  /* Raios */
  --r-xs: 8px;
  --r-sm: 12px;
  --r-md: 16px;
  --r-lg: 22px;
  --r-xl: 28px;
  --r-2xl: 36px;
  --r-pill: 999px;

  /* Sombras */
  --sh-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --sh-md: 0 8px 24px -8px rgba(0, 0, 0, 0.6);
  --sh-lg: 0 24px 60px -20px rgba(0, 0, 0, 0.75);
  --sh-glow: 0 0 0 1px var(--brand-soft-2), 0 12px 40px -12px rgba(255, 107, 0, 0.45);

  --wrap: 1220px;
  --header-h: 76px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
.display {
  font-family: "Sora", "Inter", sans-serif;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

a {
  color: inherit;
  text-decoration: none;
}

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

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

ul {
  list-style: none;
}

::selection {
  background: var(--brand);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------------- Layout ---------------- */

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}

.section {
  padding-block: clamp(56px, 8vw, 104px);
}

.section-sm {
  padding-block: clamp(40px, 5vw, 64px);
}

.stack {
  display: flex;
  flex-direction: column;
}

.row {
  display: flex;
  align-items: center;
}

.wrap-row {
  flex-wrap: wrap;
}

.between {
  justify-content: space-between;
}

.center {
  justify-content: center;
}

.grow {
  flex: 1;
}

.gap-6 { gap: 6px; }
.gap-8 { gap: 8px; }
.gap-10 { gap: 10px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-20 { gap: 20px; }
.gap-24 { gap: 24px; }
.gap-32 { gap: 32px; }
.gap-40 { gap: 40px; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-40 { margin-top: 40px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }

/* ---------------- Tipografia utilitária ---------------- */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: "Sora", sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: var(--brand);
}

.h-xl {
  font-size: clamp(38px, 6.2vw, 74px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.h-lg {
  font-size: clamp(30px, 4.2vw, 50px);
  font-weight: 800;
  letter-spacing: -0.035em;
}

.h-md {
  font-size: clamp(24px, 2.6vw, 34px);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.h-sm {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.lead {
  font-size: clamp(16px, 1.5vw, 19px);
  color: var(--text-2);
  line-height: 1.65;
  max-width: 62ch;
}

.muted {
  color: var(--text-2);
}

.dim {
  color: var(--text-3);
}

.text-sm { font-size: 14px; }
.text-xs { font-size: 13px; }
.mono { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; }
.center-text { text-align: center; }
.mx-auto { margin-inline: auto; }
.nowrap { white-space: nowrap; }

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

.grad-text {
  background: linear-gradient(100deg, var(--brand-2) 0%, var(--brand) 55%, #ff4d00 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ---------------- Botões ---------------- */

.btn {
  --btn-bg: var(--surface-2);
  --btn-fg: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: "Sora", sans-serif;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.18s var(--ease), background 0.18s, border-color 0.18s,
    box-shadow 0.18s, color 0.18s;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn svg {
  width: 17px;
  height: 17px;
  flex: none;
}

.btn-primary {
  --btn-bg: linear-gradient(135deg, var(--brand-2), var(--brand) 60%, var(--brand-3));
  --btn-fg: #fff;
  border-color: transparent;
  box-shadow: 0 8px 22px -8px rgba(255, 107, 0, 0.65);
}

.btn-primary:hover {
  box-shadow: 0 14px 32px -10px rgba(255, 107, 0, 0.8);
}

.btn-ghost {
  --btn-bg: transparent;
  border-color: var(--line);
}

.btn-ghost:hover {
  --btn-bg: var(--surface-2);
  border-color: var(--surface-3);
}

.btn-soft {
  --btn-bg: var(--brand-soft);
  --btn-fg: var(--brand-2);
  border-color: var(--brand-soft-2);
}

.btn-soft:hover {
  --btn-bg: rgba(255, 107, 0, 0.2);
}

.btn-lg {
  padding: 16px 30px;
  font-size: 15.5px;
}

.btn-sm {
  padding: 9px 16px;
  font-size: 13px;
}

.btn-block {
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ---------------- Cards ---------------- */

.card {
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg-2) 100%);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  transition: border-color 0.22s, transform 0.22s var(--ease), box-shadow 0.22s;
}

.card-pad {
  padding: 26px;
}

.card-hover:hover {
  border-color: var(--brand-soft-2);
  transform: translateY(-4px);
  box-shadow: var(--sh-lg);
}

.card-glass {
  background: var(--glass-3);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* ---------------- Pills / Badges ---------------- */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--surface-2);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  white-space: nowrap;
}

.pill-brand {
  background: var(--brand-soft);
  border-color: var(--brand-soft-2);
  color: var(--brand-2);
}

.pill-ok {
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.3);
  color: #4ade80;
}

.pill-warn {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
  color: #fbbf24;
}

.pill-info {
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.3);
  color: #60a5fa;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand);
  flex: none;
}

.dot-pulse {
  position: relative;
}

.dot-pulse::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid var(--brand);
  animation: pulse 2s var(--ease) infinite;
}

@keyframes pulse {
  0% { transform: scale(0.7); opacity: 0.9; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* ---------------- Formulários ---------------- */

.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

.label span.req {
  color: var(--brand);
}

.input,
.select,
.textarea {
  width: 100%;
  padding: 13px 16px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  color: var(--text);
  font-size: 15px;
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}

.input::placeholder,
.textarea::placeholder {
  color: var(--text-3);
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
  background: var(--surface);
}

.input[aria-invalid="true"],
.textarea[aria-invalid="true"] {
  border-color: #ef4444;
}

.textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236f757e' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 42px;
  cursor: pointer;
}

.err {
  font-size: 12.5px;
  color: #f87171;
}

/* ---------------- Grade ---------------- */

.grid {
  display: grid;
  gap: 22px;
}

.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-auto { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.g-auto-sm { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.g-auto-lg { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

/* ---------------- Divisores e superfícies ---------------- */

.hr {
  height: 1px;
  background: var(--line-soft);
  border: 0;
}

.panel {
  background: var(--bg-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: 28px;
}

.glow-orange {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  pointer-events: none;
  z-index: 0;
}

/* Cabeçalho de página */
.page-head {
  position: relative;
  padding-block: clamp(48px, 7vw, 82px) clamp(32px, 4vw, 52px);
  border-bottom: 1px solid var(--line-soft);
  overflow: hidden;
}

.page-head::after {
  content: none;
}

.page-head > * {
  position: relative;
  z-index: 1;
}

/* ---------------- Animações ---------------- */

[data-reveal] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}

[data-reveal].in {
  opacity: 1;
  transform: none;
}

.spin {
  width: 17px;
  height: 17px;
  border: 2px solid rgba(255, 255, 255, 0.28);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.skeleton {
  background: linear-gradient(90deg, var(--surface) 25%, var(--surface-3) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.3s infinite;
  border-radius: var(--r-md);
}

@keyframes shimmer {
  to { background-position: -200% 0; }
}

/* ---------------- Responsivo ---------------- */

@media (max-width: 1000px) {
  .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .wrap { padding-inline: 18px; }
  .g-2, .g-3, .g-4, .g-auto, .g-auto-sm, .g-auto-lg {
    grid-template-columns: minmax(0, 1fr);
  }
  .card-pad { padding: 20px; }
  .panel { padding: 20px; }
  .btn-lg { padding: 15px 24px; font-size: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1; transform: none; }
}
