/* =========================================================
   Talentos FML — estilos baseados no Design System "Família"
   (tokens copiados de tokens/colors.css, typography.css,
   spacing.css e base.css do pacote do Design System)
   ========================================================= */

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

:root {
  /* --- Brand raw palette --- */
  --orange-500: #ff492c;
  --orange-600: #e63a20;
  --orange-400: #ff6e57;
  --orange-100: #ffe7e1;

  --blue-500: #0063f3;
  --blue-600: #0050cc;
  --blue-100: #d6e6ff;

  --indigo-700: #091778;
  --indigo-900: #060f4f;

  --ice-100: #e7f3f7;
  --ice-50: #f4f9fb;

  --ink-900: #0a1421;
  --ink-700: #1d2a3a;
  --ink-500: #4a5765;
  --ink-300: #8b97a5;
  --ink-100: #d5dce3;

  --black: #000000;
  --white: #ffffff;

  --surface-page: var(--white);
  --surface-raised: var(--white);
  --surface-sunken: var(--ice-50);
  --surface-wash: var(--ice-100);
  --surface-inverse: var(--ink-900);
  --surface-brand: var(--orange-500);
  --surface-deep: var(--indigo-700);

  --text-strong: var(--ink-900);
  --text-body: var(--ink-700);
  --text-muted: var(--ink-500);
  --text-faint: var(--ink-300);
  --text-on-brand: var(--white);
  --text-on-dark: var(--white);
  --text-on-dark-muted: rgba(255, 255, 255, 0.66);
  --text-brand: var(--orange-500);
  --text-link: var(--blue-500);

  --border-subtle: var(--ink-100);
  --border-strong: var(--ink-900);
  --border-brand: var(--orange-500);
  --border-on-dark: rgba(255, 255, 255, 0.16);

  --success: #1d8a4e;
  --success-bg: #e3f5ea;
  --warning: #e8a020;
  --danger: var(--orange-600);
  --danger-bg: var(--orange-100);
  --info: var(--blue-500);

  --focus-ring: var(--blue-500);

  /* --- Type --- */
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Space Grotesk", system-ui, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", monospace;

  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  --text-display-lg: clamp(2.25rem, 4.4vw, 3.4rem);
  --text-h1: clamp(1.75rem, 3vw, 2.5rem);
  --text-h2: clamp(1.4rem, 2.2vw, 1.875rem);
  --text-h3: 1.375rem;
  --text-h4: 1.125rem;
  --text-lead: 1.25rem;
  --text-body-lg: 1.0625rem;
  --text-body: 1rem;
  --text-body-sm: 0.9375rem;
  --text-caption: 0.8125rem;
  --text-eyebrow: 0.8125rem;

  --leading-tight: 1.08;
  --leading-snug: 1.18;
  --leading-normal: 1.5;
  --leading-relaxed: 1.65;

  --tracking-tight: -0.02em;
  --tracking-snug: -0.01em;
  --tracking-eyebrow: 0.16em;

  /* --- Spacing / radii / shadows / motion --- */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;

  --container-max: 1200px;
  --container-pad: clamp(1.25rem, 5vw, 4rem);
  --section-y: clamp(3rem, 7vw, 6rem);

  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-pill: 999px;
  --radius-card: var(--radius-lg);

  --shadow-xs: 0 1px 2px rgba(10, 20, 33, 0.06);
  --shadow-sm: 0 2px 8px rgba(10, 20, 33, 0.08);
  --shadow-md: 0 10px 28px rgba(10, 20, 33, 0.1);
  --shadow-lg: 0 24px 60px rgba(10, 20, 33, 0.14);
  --shadow-brand: 0 14px 34px rgba(255, 73, 44, 0.28);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 140ms;
  --dur-base: 240ms;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-body);
  font-weight: var(--weight-regular);
  line-height: var(--leading-normal);
  color: var(--text-body);
  background: var(--surface-page);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text-strong);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}

p { margin: 0; }
a { color: var(--text-link); text-decoration: none; }

::selection { background: var(--orange-500); color: var(--white); }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }

.fa-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: var(--text-eyebrow);
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--text-brand);
  font-weight: var(--weight-medium);
}
.fa-eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

/* ---------------- Header ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
}
.site-header .container {
  height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.site-header img.logo { height: 26px; display: block; }
.site-header .title-lockup { display: flex; align-items: center; gap: 10px; }
.site-header .title-lockup span.name {
  font-family: var(--font-display); font-weight: 600; font-size: 16px; color: var(--ink-900);
  border-left: 1px solid var(--border-subtle); padding-left: 10px;
}
.site-header nav a {
  font-family: var(--font-display); font-weight: 500; font-size: 14.5px; color: var(--text-muted);
}

/* ---------------- Hero ---------------- */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--ice-50);
  border-bottom: 1px solid var(--border-subtle);
}
.hero .container {
  padding-top: clamp(2.25rem, 6vw, 4rem);
  padding-bottom: clamp(2rem, 6vw, 3.5rem);
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.hero h1 {
  font-size: var(--text-display-lg);
  letter-spacing: -0.025em;
  margin-top: 14px;
  max-width: 16ch;
}
.hero h1 .accent { color: var(--orange-500); }
.hero p.lead {
  font-size: var(--text-lead);
  color: var(--text-muted);
  margin-top: 14px;
  max-width: 46ch;
  line-height: 1.55;
}
.hero .flower {
  position: absolute;
  opacity: 1;
  pointer-events: none;
}
.hero .stats { display: flex; gap: 22px; margin-top: 26px; flex-wrap: wrap; }
.hero .stat .n { font-family: var(--font-display); font-weight: 700; font-size: 26px; color: var(--ink-900); line-height: 1; }
.hero .stat .l { font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); letter-spacing: 0.04em; margin-top: 4px; }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  border-radius: var(--radius-pill);
  transition: transform var(--dur-fast) var(--ease-out), filter var(--dur-fast) var(--ease-out);
  height: 48px;
  padding: 0 22px;
  font-size: 16px;
  border: 1px solid transparent;
}
.btn:active { transform: scale(0.97); }
.btn:hover { filter: brightness(0.94); }
.btn-primary { background: var(--orange-500); color: var(--white); box-shadow: var(--shadow-brand); }
.btn-secondary { background: var(--ink-900); color: var(--white); box-shadow: var(--shadow-sm); }
.btn-outline { background: transparent; color: var(--ink-900); border-color: var(--ink-900); }
.btn-ghost { background: transparent; color: var(--ink-900); }
.btn-sm { height: 38px; padding: 0 16px; font-size: 14.5px; }
.btn[disabled] { background: var(--ink-100); color: var(--text-muted); box-shadow: none; cursor: not-allowed; }
.btn[disabled]:hover { filter: none; }

/* ---------------- Filter bar ---------------- */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  padding: var(--space-5) 0;
}
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label, .ff-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.field input[type="text"],
.field input[type="search"],
.field select,
.ff-input,
.ff-select,
.ff-textarea {
  display: block;
  width: 100%;
  font-family: var(--font-body);
  font-size: 15.5px;
  color: var(--text-strong);
  background: var(--white);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 11px 14px;
  outline: none;
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.field input:focus, .field select:focus, .ff-input:focus, .ff-select:focus, .ff-textarea:focus {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px var(--blue-100);
}
.field.grow { flex: 1; min-width: 200px; }
.field select, .field input { min-width: 170px; }

/* ---------------- Grid & cards ---------------- */
.section { padding: var(--space-6) 0 var(--space-8); }
.grid-header { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: var(--space-4); }
.grid-count { font-family: var(--font-mono); font-size: 12.5px; color: var(--text-muted); }

.talent-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 18px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.card h3 { font-size: var(--text-h4); }
.card .profissao { font-size: 14.5px; color: var(--text-muted); margin-top: 2px; font-weight: 500; }
.card .badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.card .desc { font-size: 14px; color: var(--text-body); margin-top: 12px; line-height: 1.55; }
.card .desc .label { font-family: var(--font-mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-faint); display: block; margin-bottom: 3px; }
.card .foot { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border-subtle); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.card .foot a.curriculo,
.card .foot button.curriculo {
  font-family: var(--font-display); font-weight: 600; font-size: 13.5px; color: var(--blue-500);
  background: none; border: none; padding: 0; cursor: pointer;
}
.card .foot a.whatsapp { font-family: var(--font-display); font-weight: 600; font-size: 13.5px; color: var(--success); }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  letter-spacing: 0.05em; text-transform: uppercase;
  padding: 5px 10px; border-radius: var(--radius-pill); line-height: 1;
}
.badge-area { background: var(--blue-100); color: var(--blue-600); }
.badge-estatus { background: var(--ice-100); color: var(--ink-700); }
.badge-disp-sim { background: var(--success-bg); color: var(--success); }
.badge-disp-nao { background: var(--danger-bg); color: var(--danger); }

.empty-state, .loading-state {
  text-align: center;
  padding: var(--space-8) var(--space-4);
  color: var(--text-muted);
  font-family: var(--font-body);
  border: 1.5px dashed var(--border-subtle);
  border-radius: var(--radius-lg);
}

/* ---------------- Modal ---------------- */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(10, 20, 33, 0.62);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal-overlay[hidden] { display: none; }
.modal {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  width: 100%; max-width: 560px; max-height: 90vh;
  display: flex; flex-direction: column;
  overflow: hidden; /* garante que nada vaze para fora dos cantos arredondados */
}
.modal-header {
  padding: 20px 26px 16px; border-bottom: 1px solid var(--border-subtle);
  display: flex; align-items: center; justify-content: space-between; flex-shrink: 0;
}
.modal-header .title { font-family: var(--font-display); font-weight: 600; font-size: 19px; color: var(--ink-900); }
.modal-close {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border-subtle);
  background: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--text-muted); font-size: 21px; line-height: 1;
}
/* O <form> fica entre o header e o body/footer — precisa ser um flex item que
   também é um flex container, senão o modal-body nunca recebe uma altura
   limitada e o overflow-y:auto não funciona, fazendo o conteúdo vazar para
   fora do card (o bug do formulário "quebrado"). */
#form-cadastro { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.modal-body { overflow-y: auto; flex: 1; min-height: 0; padding: 18px 26px 6px; }
.modal-footer { padding: 16px 26px 22px; border-top: 1px solid var(--border-subtle); flex-shrink: 0; }

.ff-field { margin-bottom: 18px; }
.ff-label { margin-bottom: 8px; }
.ff-row { display: flex; gap: 12px; }
.ff-row > .ff-field { flex: 1; }
.ff-hint { font-size: 12.5px; color: var(--text-faint); margin-top: 5px; display: block; }
.ff-checks { display: flex; flex-direction: column; gap: 2px; }
.ff-check-label { display: flex; align-items: center; gap: 10px; padding: 7px 0; cursor: pointer; font-size: 15px; color: var(--text-strong); }
.ff-check-label input { width: 18px; height: 18px; accent-color: var(--orange-500); cursor: pointer; }
.ff-radio-group { display: flex; gap: 22px; flex-wrap: wrap; }
.ff-radio-label { display: flex; align-items: center; gap: 9px; cursor: pointer; font-size: 15.5px; color: var(--text-strong); padding: 6px 0; }
.ff-radio-label input { width: 18px; height: 18px; accent-color: var(--orange-500); cursor: pointer; }
.ff-file { font-family: var(--font-body); font-size: 14.5px; }

.success-panel { padding: 40px 24px 30px; text-align: center; }
.success-panel .flower-wrap { display: flex; justify-content: center; }
.success-panel h3 { font-size: 24px; margin-top: 18px; }
.success-panel p { font-size: 15.5px; color: var(--text-muted); line-height: 1.6; max-width: 34ch; margin: 12px auto 0; }

.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(140%);
  background: var(--ink-900); color: #fff; padding: 14px 22px; border-radius: var(--radius-pill);
  font-family: var(--font-display); font-weight: 600; font-size: 14.5px; box-shadow: var(--shadow-lg);
  transition: transform var(--dur-base) var(--ease-out), opacity var(--dur-base) var(--ease-out);
  z-index: 300; pointer-events: none; max-width: 90vw; text-align: center;
  opacity: 0; visibility: hidden;
}
.toast.show { transform: translateX(-50%) translateY(0); opacity: 1; visibility: visible; }

.site-footer { border-top: 1px solid var(--border-subtle); padding: var(--space-6) 0; }
.site-footer .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.site-footer p { font-size: 13px; color: var(--text-faint); }
.site-footer a { font-size: 13px; color: var(--text-faint); }

@media (max-width: 640px) {
  .filters { flex-direction: column; align-items: stretch; }
  .field select, .field input { min-width: 0; width: 100%; }
  .ff-row { flex-direction: column; gap: 0; }
}
