/* Reserva com métricas ajustadas ao Space Grotesk (evita "pulo" de layout ao carregar a fonte) */
@font-face {
  font-family: "Space Grotesk Fallback";
  src: local("Arial"), local("Helvetica Neue"), local("Helvetica"), local("Liberation Sans");
  size-adjust: 101.24%;
  ascent-override: 97.2%;
  descent-override: 28.84%;
  line-gap-override: 0%;
}

:root {
  --r: 18px;
  --r-lg: 24px;

  --bg: #0a0a0a;
  --text: #f5f5f5;
  --muted: #9a9a9f;
  --faint: #626266;

  --focus: #d4d4d8;
  --green: #34d27b;
  --purple: #a78bfa;

  --glass: rgba(255, 255, 255, 0.03);
  --glass-hover: rgba(255, 255, 255, 0.055);
  --line: rgba(255, 255, 255, 0.075);

  --ease: cubic-bezier(0.22, 0.9, 0.3, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

html { color-scheme: dark; -webkit-text-size-adjust: 100%; background: var(--bg); }

body {
  min-height: 100vh;
  min-height: 100dvh;
  color: var(--text);
  background:
    radial-gradient(90% 38% at 50% -6%, rgba(255, 255, 255, 0.065), transparent 72%),
    radial-gradient(70% 30% at 50% 108%, rgba(255, 255, 255, 0.03), transparent 72%),
    var(--bg);
  background-attachment: fixed;
  font-family: "Space Grotesk", "Space Grotesk Fallback", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

.wrap {
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
  padding: max(32px, env(safe-area-inset-top)) 18px max(28px, env(safe-area-inset-bottom));
}

/* ---------- Entrance (opacity only on cheap properties) ---------- */
.reveal {
  opacity: 0;
  transform: translateY(8px);
  animation: rise 0.5s var(--ease) forwards;
  animation-delay: calc(var(--i, 0) * 50ms);
}
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Hero ---------- */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 4px 8px 24px;
}

.hero__logo {
  position: relative;
  display: grid;
  place-items: center;
  width: 118px;
  height: 118px;
  margin-bottom: 4px;
}
.hero__logo img {
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: var(--r-lg);
}
.ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.hero__name {
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.1;
}
.hero__desc {
  margin-top: 8px;
  max-width: 310px;
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--muted);
  text-wrap: balance;
}

/* ---------- Groups / labels ---------- */
.group { margin-top: 20px; display: flex; flex-direction: column; gap: 10px; }
.group:first-of-type { margin-top: 0; }

.label {
  padding-left: 4px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--faint);
}

/* ---------- Cards ---------- */
.card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px 14px 12px 12px;
  color: var(--text);
  text-decoration: none;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: background-color 0.25s, border-color 0.25s, transform 0.2s var(--ease);
}

.card__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.card__title { font-size: 0.9rem; font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; }
.card__desc { font-size: 0.74rem; font-weight: 500; line-height: 1.45; color: var(--muted); text-wrap: pretty; }

.card__arrow {
  display: grid;
  place-items: center;
  width: 26px; height: 26px;
  color: #a8a8ad;
  transition: transform 0.25s var(--ease), color 0.25s;
}
.card__arrow svg { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

@media (hover: hover) {
  .card:hover { background: var(--glass-hover); border-color: rgba(255, 255, 255, 0.14); }
  .card:hover .card__arrow { transform: translateX(2px); color: #fff; }
}
.card:active { transform: scale(0.985); transition-duration: 0.1s; }
.card:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ---------- Icons ---------- */
.icon {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: 13px;
  border: 1px solid transparent;
}
.icon svg { width: 22px; height: 22px; }
.icon--green { color: var(--green); background: rgba(52, 210, 123, 0.12); border-color: rgba(52, 210, 123, 0.2); }
.icon--purple { color: var(--purple); background: rgba(139, 92, 246, 0.16); border-color: rgba(139, 92, 246, 0.26); }
.icon--biz { color: #e4e4e7; background: rgba(255, 255, 255, 0.07); border-color: rgba(255, 255, 255, 0.14); }
.icon--community { background: rgba(52, 210, 123, 0.1); border-color: rgba(52, 210, 123, 0.18); }
.icon--community svg { width: 24px; height: 24px; }
.icon--community .g-main { stroke: #f5f5f5; }
.icon--community .g-side { stroke: var(--green); }

/* ---------- Primary card (tema Lovable) ---------- */
.card--primary {
  --lovable: linear-gradient(135deg, #ff7a00 0%, #ff4433 35%, #d65cf0 72%, #4a7bff 100%);
  position: relative;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 14px;
  padding: 16px 14px 16px 14px;
  border-color: transparent;
  background:
    linear-gradient(135deg, rgba(255, 122, 0, 0.13) 0%, rgba(255, 68, 51, 0.09) 35%, rgba(214, 92, 240, 0.09) 70%, rgba(74, 123, 255, 0.13) 100%);
}
/* gradient hairline border */
.card--primary::before {
  content: "";
  position: absolute;
  inset: 0;
  padding: 1px;
  border-radius: inherit;
  background: var(--lovable);
  opacity: 0.55;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  pointer-events: none;
  transition: opacity 0.25s;
}
.card--primary .card__body { gap: 4px; padding-right: 0; }
.card--primary .card__title { font-size: 0.98rem; font-weight: 700; letter-spacing: -0.015em; }
.card--primary .card__desc { color: rgba(236, 240, 250, 0.72); font-size: 0.76rem; }

.card--primary .card__arrow {
  position: absolute;
  top: 14px; right: 14px;
  width: 28px; height: 28px;
  border-radius: 50%;
  color: #fff;
  background: var(--lovable);
}

.icon--primary {
  width: 48px; height: 48px;
  background: rgba(0, 0, 0, 0.4);
  border-color: rgba(255, 255, 255, 0.1);
}
.icon--primary img { width: 28px; height: 28px; object-fit: contain; display: block; }

@media (hover: hover) {
  .card--primary:hover { background:
    linear-gradient(135deg, rgba(255, 122, 0, 0.18) 0%, rgba(255, 68, 51, 0.12) 35%, rgba(214, 92, 240, 0.12) 70%, rgba(74, 123, 255, 0.18) 100%); }
  .card--primary:hover::before { opacity: 0.9; }
  .card--primary:hover .card__arrow { color: #fff; }
}

.chip {
  align-self: flex-start;
  margin-bottom: 2px;
  padding: 3px 9px;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #ffd9c2;
  background: rgba(255, 122, 0, 0.14);
  border: 1px solid rgba(255, 122, 0, 0.3);
  border-radius: 999px;
}

/* ---------- Footer ---------- */
.foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
  padding-top: 22px;
  text-align: center;
  border-top: 1px solid var(--line);
}

.socials { display: flex; justify-content: center; gap: 8px; }
.socials a {
  display: grid;
  place-items: center;
  width: 42px; height: 42px;
  color: #b4b4b9;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: background-color 0.25s, color 0.25s, transform 0.2s var(--ease);
}
@media (hover: hover) {
  .socials a:hover { color: #fff; background: var(--glass-hover); }
}
.socials a:active { transform: scale(0.94); }
.socials a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.brand { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; font-weight: 700; letter-spacing: -0.01em; }
.brand img { border-radius: 7px; }
.disclaimer { max-width: 290px; font-size: 0.68rem; font-weight: 500; line-height: 1.5; color: var(--faint); }
.copy { font-size: 0.64rem; font-weight: 500; color: #48484c; }

/* ---------- Larger screens ---------- */

@media (min-width: 640px) {
  .wrap { padding-top: 56px; }
}

@media (max-width: 360px) {
  .wrap { padding-left: 14px; padding-right: 14px; }
  .card { gap: 10px; }
  .icon { width: 40px; height: 40px; }
  .card--primary .card__title { font-size: 0.9rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}
