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

/* ---- CSS Variables (reproduz globals.css :root) ---- */
:root {
  --background: #ffffff;
  --foreground: #020817;
  --card: #ffffff;
  --card-foreground: #020817;
  --primary: #742774;
  --primary-foreground: #ffffff;
  --border: #e2e8f0;
  --input: #e2e8f0;
  --ring: #742774;
  --muted-foreground: #64748b;
  --radius: 0.5rem;
}

/* ---- Body / Page ---- */
html,
body {
  height: 100%;
}

body {
  font-family: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: #f9fafb; /* bg-gray-50 */
  color: var(--foreground);
  line-height: 1.5;
}

/* ---- Page wrapper (centraliza o card) ---- */
.page-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem; /* px-4 */
}

/* ---- Card ---- */
.card {
  width: 100%;
  max-width: 28rem; /* max-w-md (448px) */
  padding: 2rem; /* p-8 */
  background-color: var(--card);
  color: var(--card-foreground);
  display: flex;
  flex-direction: column;
  gap: 1.5rem; /* gap-6 */
  border-radius: 0.75rem; /* rounded-xl */
  border: 1px solid var(--border);
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); /* shadow-sm */
}

/* space-y-6 — empilha com gap + margin */
.card > * + * {
  margin-top: 1.5rem;
}

/* ---- Logo ---- */
.logo-container {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem; /* mb-6 */
}

.logo-container img {
  width: 200px;
  height: auto;
}

/* ---- Form ---- */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 1rem; /* space-y-4 */
}

/* ---- Field group ---- */
.field-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem; /* space-y-2 */
}

/* ---- Label ---- */
.field-label {
  font-size: 0.875rem; /* text-sm */
  line-height: 1; /* leading-none */
  font-weight: 500; /* font-medium */
  user-select: none;
}

/* ---- Input ---- */
.field-input {
  height: 2.25rem; /* h-9 */
  width: 100%;
  min-width: 0;
  border-radius: calc(var(--radius) - 2px); /* rounded-md */
  border: 1px solid var(--input);
  background-color: transparent;
  padding: 0.25rem 0.75rem; /* py-1 px-3 */
  font-size: 0.875rem; /* text-sm */
  font-family: inherit;
  color: inherit;
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); /* shadow-xs */
  outline: none;
  transition: color 0.15s, box-shadow 0.15s, border-color 0.15s;
}

.field-input::placeholder {
  color: var(--muted-foreground);
}

.field-input:focus {
  border-color: var(--ring);
  box-shadow: 0 0 0 3px rgb(116 39 116 / 0.25); /* ring */
}

/* ---- Button ---- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  white-space: nowrap;
  height: 2.5rem; /* h-10 (size lg) */
  padding: 0 1.5rem; /* px-6 */
  width: 100%;
  border: none;
  border-radius: calc(var(--radius) - 2px); /* rounded-md */
  font-family: inherit;
  font-size: 0.875rem; /* text-sm */
  font-weight: 500;
  background-color: var(--primary);
  color: var(--primary-foreground);
  cursor: pointer;
  transition: background-color 0.15s;
  outline: none;
}

.btn-primary:hover {
  background-color: #5a1f5a;
}

.btn-primary:active {
  background-color: #4a184a;
}

.btn-primary:focus-visible {
  box-shadow: 0 0 0 3px rgb(116 39 116 / 0.25);
}
