/* ==========================================================================
   PH Investimentos — tema (reskin pixel a pixel do front original).
   Tokens extraídos do CSS compilado (Tailwind v4) das capturas. Tema claro.
   ========================================================================== */
:root {
  /* Marca (verde candlestick) */
  --brand-50:#eefaef; --brand-100:#d9f3db; --brand-200:#b8e8bc; --brand-300:#86d78c;
  --brand-400:#1baf24; --brand-500:#16991f; --brand-600:#0f7a1a; --brand-700:#0b5e16;
  --brand-800:#064214; --brand-900:#012c10; --brand-glow:24 128 34;

  /* Neutros */
  --bg:#fff; --fg:#1a1b1e; --subtle:#45474c; --muted:#848589; --border:#dbdce3;
  --surface-1:#fafafd; --surface-2:#f2f3f7; --surface-3:#eceef4; --surface-4:#dbdce3;

  /* Papéis / status */
  --investidor:#2d7fd6; --lider:#7b5be0; --gold:#e2ae45;
  --danger:#a13636; --danger-surface:#fbf0ee;

  /* Raios */
  --r-sm:.25rem; --r-md:.375rem; --r-lg:.5rem; --r-xl:.75rem; --r-2xl:1rem; --r-3xl:1.5rem; --r-4xl:2rem;

  --font:"Work Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --logo-texto:#1a1b1e; /* cor do wordmark "INVESTIMENTOS" no logo SVG */
}

*, *::before, *::after { box-sizing:border-box; }
html { -webkit-text-size-adjust:100%; }
body {
  margin:0; font-family:var(--font); color:var(--fg); background:var(--surface-2);
  -webkit-font-smoothing:antialiased; text-rendering:optimizeLegibility;
  overflow-x:hidden;
}

/* ============================ Layout de auth ============================= */
.ph-auth {
  min-height:100dvh; display:flex; flex-direction:column;
  padding:24px 24px 20px; gap:18px;
}
.ph-auth__stage { flex:1; display:flex; align-items:center; justify-content:center; }

.ph-card {
  width:100%; max-width:1180px; min-width:0; background:var(--bg);
  border-radius:var(--r-4xl); box-shadow:0 1px 2px rgba(16,24,40,.04), 0 24px 60px -24px rgba(16,24,40,.18);
  display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1.08fr);
  gap:28px; padding:28px; align-items:stretch;
}
.ph-pane { padding:30px 34px; display:flex; flex-direction:column; min-width:0; }
.ph-pane--narrow { max-width:520px; }

/* Logo */
.ph-logo { display:inline-flex; height:52px; margin-bottom:26px; }
.ph-logo svg { height:100%; width:auto; }

/* Títulos */
.ph-h1 { font-size:30px; font-weight:700; letter-spacing:-.01em; margin:0 0 10px; color:var(--fg); }
.ph-sub { font-size:15.5px; line-height:1.5; color:var(--subtle); margin:0 0 26px; max-width:40ch; }
.ph-sub b, .ph-sub strong { color:var(--brand-600); font-weight:600; }

/* Campos */
.ph-field { display:block; margin-bottom:18px; }
.ph-label { display:block; font-size:14.5px; font-weight:600; color:var(--fg); margin-bottom:9px; }
.ph-input {
  width:100%; height:56px; padding:0 18px; font:inherit; font-size:16px; color:var(--fg);
  background:var(--bg); border:1.5px solid var(--border); border-radius:var(--r-2xl);
  outline:none; transition:border-color .15s, box-shadow .15s;
}
.ph-input::placeholder { color:var(--muted); }
.ph-input:focus { border-color:var(--brand-400); box-shadow:0 0 0 4px rgb(var(--brand-glow) / .12); }
.ph-input--filled { background:var(--surface-2); border-color:transparent; }

.ph-pwd { position:relative; display:block; }
.ph-pwd .ph-input { padding-right:52px; }
.ph-eye {
  position:absolute; right:10px; top:50%; transform:translateY(-50%);
  width:38px; height:38px; display:grid; place-items:center; border:0; background:none;
  color:var(--muted); cursor:pointer; border-radius:var(--r-lg);
}
.ph-eye:hover { color:var(--subtle); }
.ph-hint { font-size:13.5px; color:var(--muted); margin:8px 2px 0; line-height:1.45; }
.ph-err { display:block; font-size:13.5px; color:var(--danger); margin:8px 2px 0; }

/* Checkbox redondo */
.ph-check { display:flex; align-items:center; gap:11px; margin:4px 0 22px; cursor:pointer; user-select:none; }
.ph-check input { position:absolute; opacity:0; width:0; height:0; }
.ph-check__box {
  width:22px; height:22px; border-radius:999px; border:1.8px solid var(--border);
  display:grid; place-items:center; flex:none; transition:background .15s, border-color .15s;
}
.ph-check input:checked + .ph-check__box { background:var(--brand-400); border-color:var(--brand-400); }
.ph-check__box svg { width:13px; height:13px; color:#fff; opacity:0; }
.ph-check input:checked + .ph-check__box svg { opacity:1; }
.ph-check__label { font-size:15px; color:var(--subtle); }

/* Botões */
.ph-btn {
  width:100%; height:58px; display:inline-flex; align-items:center; justify-content:center; gap:10px;
  font:inherit; font-size:16.5px; font-weight:700; border-radius:999px; cursor:pointer;
  text-decoration:none; border:1.5px solid transparent;
  transition:background .15s, border-color .15s, transform .05s;
}
.ph-btn:active { transform:translateY(1px); }
.ph-btn svg { width:20px; height:20px; }
.ph-btn--primary { background:var(--brand-500); color:#fff; box-shadow:0 8px 16px -11px rgb(var(--brand-glow) / .6); }
.ph-btn--primary:hover { background:var(--brand-600); }
.ph-btn--ghost { background:var(--bg); color:var(--fg); border-color:var(--border); }
.ph-btn--ghost:hover { background:var(--surface-1); }
.ph-btn--google { background:var(--bg); color:var(--fg); border-color:var(--border); }
.ph-btn--google:hover { background:var(--surface-1); }
.ph-gicon { width:20px; height:20px; }

/* Divisor "ou" */
.ph-or { display:flex; align-items:center; gap:14px; margin:20px 0; color:var(--muted); font-size:14px; }
.ph-or::before, .ph-or::after { content:""; height:1px; flex:1; background:var(--border); }

/* Linha de ajuda (recuperar senha) */
.ph-help { display:flex; align-items:center; justify-content:center; gap:10px; margin-top:22px; font-size:15px; color:var(--subtle); }
.ph-pill-link {
  display:inline-flex; align-items:center; gap:7px; padding:8px 14px; border-radius:999px;
  background:var(--brand-50); color:var(--brand-700); font-weight:600; text-decoration:none;
}
.ph-pill-link:hover { background:var(--brand-100); }
.ph-pill-link svg { width:16px; height:16px; }

.ph-alt { text-align:center; margin-top:20px; font-size:15px; color:var(--subtle); }
.ph-alt a { color:var(--brand-600); font-weight:600; text-decoration:none; }
.ph-alt a:hover { text-decoration:underline; }

/* ============================= Hero (painel preto) ====================== */
.ph-hero {
  position:relative; border-radius:var(--r-3xl); background:#0a0a0a; overflow:hidden;
  min-height:520px; color:#fff; isolation:isolate;
}
.ph-hero__copy { position:absolute; left:30px; bottom:28px; z-index:3; }
.ph-hero__copy h2 { margin:0; font-size:30px; font-weight:700; line-height:1.1; letter-spacing:-.01em; }
.ph-hero__copy h2 span { color:#9aa0a6; }

/* Globo (login) */
.ph-globe { position:absolute; inset:0; display:grid; place-items:center; }
.ph-globe__svg { width:78%; max-width:520px; filter:drop-shadow(0 0 60px rgb(var(--brand-glow) / .35)); }
.ph-city {
  position:absolute; z-index:4; background:#111; border:1px solid #2a2a2a; border-radius:8px;
  padding:5px 9px; font-size:11.5px; line-height:1.15; white-space:nowrap;
  box-shadow:0 6px 16px rgba(0,0,0,.5);
}
.ph-city b { display:block; font-weight:600; font-size:12px; }
.ph-city small { color:#8a8f94; font-size:10.5px; }
.ph-city::before { content:""; position:absolute; width:7px; height:7px; border-radius:999px; background:var(--brand-400); box-shadow:0 0 10px 2px rgb(var(--brand-glow) / .8); }
.ph-city--ldn { top:14%; right:10%; } .ph-city--ldn::before { left:-11px; top:9px; }
.ph-city--nyc { top:26%; left:30%; }  .ph-city--nyc::before { left:-11px; top:9px; }
.ph-city--sp  { top:52%; right:20%; } .ph-city--sp::before  { left:-11px; top:9px; }

/* ============================== Rodapé ================================== */
.ph-foot {
  width:100%; max-width:1180px; margin:0 auto; display:flex; align-items:center;
  gap:18px; flex-wrap:wrap; font-size:13.5px; color:var(--muted);
}
.ph-foot__lang { display:inline-flex; align-items:center; gap:8px; padding:8px 12px; border-radius:999px; background:var(--bg); border:1px solid var(--border); color:var(--subtle); font-weight:500; cursor:pointer; }
.ph-foot__lang .flag { width:20px; height:14px; border-radius:2px; }
.ph-foot__socials { display:inline-flex; gap:14px; align-items:center; }
.ph-foot__socials a { color:var(--muted); display:inline-flex; }
.ph-foot__socials a:hover { color:var(--subtle); }
.ph-foot__socials svg { width:18px; height:18px; }
.ph-foot__links { display:inline-flex; gap:10px; }
.ph-foot__links a { padding:7px 13px; border-radius:999px; background:var(--surface-3); color:var(--subtle); text-decoration:none; font-weight:500; }
.ph-foot__links a:hover { background:var(--surface-4); }
.ph-foot__copy { margin-left:auto; color:var(--muted); }

/* ============================== Mobile ================================= */
@media (max-width:860px) {
  body { background:var(--bg); }
  .ph-auth { padding:22px 18px 26px; }
  .ph-card { grid-template-columns:minmax(0,1fr); box-shadow:none; border-radius:0; padding:0; max-width:none; gap:0; }
  .ph-hero { display:none; }
  .ph-pane { padding:8px 4px 0; }
  .ph-logo { height:40px; align-self:center; margin:6px 0 24px; }
  .ph-h1 { font-size:26px; }
  .ph-foot { flex-direction:column; align-items:flex-start; gap:16px; padding-top:8px; }
  .ph-foot__copy { margin-left:0; }
}

/* ============================ Wizard de cadastro ======================== */
.ph-wiz__top { position:relative; display:flex; align-items:center; flex-wrap:wrap; gap:14px; }
.ph-wiz__back { width:40px; height:40px; border-radius:999px; border:1px solid var(--border); background:var(--surface-2); color:var(--fg); display:grid; place-items:center; cursor:pointer; flex:none; }
.ph-wiz__back[hidden] { display:none; }
.ph-wiz__back svg { width:20px; height:20px; }
.ph-wiz__logo { display:inline-flex; height:46px; } .ph-wiz__logo svg { height:100%; width:auto; }
.ph-wiz__progress { flex-basis:100%; display:flex; align-items:center; gap:14px; margin-top:22px; }
.ph-wiz__bars { display:flex; gap:7px; flex:1; }
.ph-wiz__bars i { height:6px; flex:1; border-radius:999px; background:var(--surface-3); transition:background .25s; }
.ph-wiz__bars i.on { background:var(--brand-500); }
.ph-wiz__count { font-size:13.5px; color:var(--muted); white-space:nowrap; }
.ph-wiz__count b { color:var(--subtle); font-weight:600; }
.ph-wiz__step { margin-top:26px; }

.ph-invitecard { display:flex; align-items:center; gap:12px; padding:13px 16px; border-radius:var(--r-2xl); background:var(--brand-50); border:1px solid var(--brand-100); margin-bottom:24px; }
.ph-invitecard__av { width:44px; height:44px; border-radius:999px; background:#1b1b1b; color:#e2ae45; display:grid; place-items:center; font-weight:700; font-size:13px; flex:none; overflow:hidden; }
.ph-invitecard__txt { flex:1; display:flex; flex-direction:column; min-width:0; }
.ph-invitecard__txt span { font-size:13px; color:var(--brand-700); }
.ph-invitecard__txt b { font-size:16px; }
.ph-invitecard__gift { width:38px; height:38px; border-radius:999px; background:#fff; display:grid; place-items:center; color:var(--brand-600); flex:none; }
.ph-invitecard__gift svg { width:18px; height:18px; }

.ph-fakeselect { display:flex; align-items:center; gap:10px; height:56px; padding:0 18px; border:1.5px solid var(--border); border-radius:var(--r-2xl); font-size:16px; color:var(--fg); background:#fff; }
.ph-fakeselect svg { width:18px; height:18px; margin-left:auto; color:var(--muted); }

.flag-br { width:22px; height:15px; border-radius:2px; display:inline-block; flex:none;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 20'%3E%3Crect width='28' height='20' rx='2' fill='%23009b3a'/%3E%3Cpath d='M14 3 25 10 14 17 3 10z' fill='%23ffdf00'/%3E%3Ccircle cx='14' cy='10' r='4' fill='%23002776'/%3E%3C/svg%3E") center/cover no-repeat; }

.ph-phone { display:flex; align-items:stretch; }
.ph-phone__ddi { display:flex; align-items:center; gap:7px; padding:0 14px; border:1.5px solid var(--border); border-right:0; border-radius:var(--r-2xl) 0 0 var(--r-2xl); font-size:16px; color:var(--fg); background:var(--surface-1); white-space:nowrap; }
.ph-phone .ph-input { border-radius:0 var(--r-2xl) var(--r-2xl) 0; }

.ph-note { display:flex; gap:10px; align-items:flex-start; padding:14px 16px; border-radius:var(--r-xl); background:var(--surface-2); color:var(--subtle); font-size:13.5px; line-height:1.45; margin:16px 0 22px; }
.ph-note svg { width:20px; height:20px; flex:none; color:var(--muted); margin-top:1px; }

.ph-strength { display:flex; gap:6px; margin-top:12px; }
.ph-strength i { height:4px; flex:1; border-radius:999px; background:var(--surface-3); transition:background .2s; }
.ph-strength i.on { background:var(--brand-400); }
.ph-strength[data-score="1"] i.on { background:var(--danger); }
.ph-strength[data-score="2"] i.on { background:var(--gold); }

.ph-check--terms { align-items:flex-start; }
.ph-check--terms .ph-check__box { margin-top:1px; }
.ph-check__label a { color:var(--brand-600); font-weight:600; text-decoration:none; }
.ph-check__label a:hover { text-decoration:underline; }

.ph-encrypt { display:flex; align-items:center; justify-content:center; gap:7px; color:var(--muted); font-size:13px; margin-top:16px; }
.ph-encrypt svg { width:15px; height:15px; }

/* Hero de candlesticks (cadastro) */
.ph-chart { position:absolute; inset:0; }
.ph-chart__sym { position:absolute; left:28px; top:22px; font-size:12px; color:#6b7280; z-index:2; }
.ph-chart__badge { position:absolute; right:22px; top:22px; background:#111; border:1px solid #262626; border-radius:12px; padding:11px 14px; font-size:13px; font-weight:600; color:#fff; line-height:1.5; z-index:3; }
.ph-chart__badge-top { display:block; font-size:12px; color:#9ca3af; font-weight:500; margin-bottom:4px; }
.ph-chart__badge-top b { color:#38d94a; }
.ph-chart__badge span { color:#9ca3af; font-weight:500; }
.ph-chart__svg { position:absolute; left:0; right:0; top:58px; bottom:116px; width:100%; }

/* ---- Wizard: mobile ---- */
@media (max-width:860px) {
  .ph-wiz__top { justify-content:center; }
  .ph-wiz__back { position:absolute; left:0; top:0; }
  .ph-wiz__logo { height:36px; margin:0 auto; }
  .ph-wiz__progress { margin-top:26px; }
  .ph-invitecard { margin-bottom:20px; }
}

/* ============================== Páginas legais ========================== */
.phlegal { min-height:100dvh; background:#fff; display:flex; flex-direction:column; }
.phlegal__top { position:sticky; top:0; z-index:10; display:flex; align-items:center; justify-content:space-between;
  padding:16px 24px; border-bottom:1px solid var(--border); background:rgba(255,255,255,.9); backdrop-filter:blur(8px); }
.phlegal__logo { display:inline-flex; height:32px; } .phlegal__logo svg { height:100%; width:auto; }
.phlegal__back { display:inline-flex; align-items:center; gap:6px; padding:9px 15px; border-radius:999px; border:1px solid var(--border); color:var(--subtle); text-decoration:none; font-size:14px; font-weight:600; }
.phlegal__back:hover { background:var(--surface-1); }
.phlegal__back svg { width:17px; height:17px; }

.phlegal__doc { width:100%; max-width:760px; margin:0 auto; padding:40px 24px 56px; flex:1; }
.phlegal__badge { display:inline-flex; padding:6px 13px; border-radius:999px; background:var(--brand-50); color:var(--brand-700); font-size:12.5px; font-weight:600; }
.phlegal__title { font-size:34px; font-weight:800; letter-spacing:-.02em; margin:16px 0 8px; }
.phlegal__meta { color:var(--muted); font-size:14px; margin:0 0 8px; }

.phlegal__body { margin-top:14px; color:var(--subtle); }
.phlegal__body h3 { font-size:18px; font-weight:700; color:var(--fg); margin:30px 0 10px; }
.phlegal__body p { font-size:15.5px; line-height:1.7; margin:0 0 12px; }
.phlegal__body em { color:var(--muted); font-style:normal; font-size:14px; }
.phlegal__body a { color:var(--brand-600); font-weight:600; text-decoration:none; }
.phlegal__body table { width:100%; border-collapse:collapse; margin:14px 0 20px; font-size:14px; border:1px solid var(--border); border-radius:var(--r-lg); overflow:hidden; }
.phlegal__body thead th { background:var(--surface-2); text-align:left; font-weight:600; color:var(--fg); padding:11px 13px; }
.phlegal__body tbody td { padding:11px 13px; border-top:1px solid var(--border); vertical-align:top; line-height:1.5; }
.phlegal__body tbody td:first-child { font-weight:600; color:var(--fg); white-space:nowrap; }

.phlegal__return { display:inline-block; margin-top:28px; color:var(--brand-600); font-weight:600; text-decoration:none; }
.phlegal__return:hover { text-decoration:underline; }
.phlegal__foot { padding:20px 24px; border-top:1px solid var(--border); text-align:center; color:var(--muted); font-size:13px; }

@media (max-width:860px) {
  .phlegal__title { font-size:27px; }
  .phlegal__body table, .phlegal__body thead, .phlegal__body tbody, .phlegal__body tr, .phlegal__body td { display:block; }
  .phlegal__body thead { display:none; }
  .phlegal__body tbody td { border-top:0; padding:3px 13px; }
  .phlegal__body tbody tr { border-top:1px solid var(--border); padding:10px 0; }
  .phlegal__body tbody td:first-child { white-space:normal; padding-top:10px; }
}

/* ===================== Pausa de acesso (comunicado + countdown) ========= */
.ph-gate { min-height:100dvh; display:flex; flex-direction:column; align-items:center; justify-content:center; padding:32px 20px; gap:20px; }
.ph-gate__card { width:100%; max-width:560px; background:#fff; border:1px solid var(--border); border-radius:var(--r-4xl);
  box-shadow:0 1px 2px rgba(16,24,40,.04), 0 24px 60px -24px rgba(16,24,40,.18); padding:38px 36px 34px; text-align:center; }
.ph-gate__logo { height:46px; margin:0 auto 22px; }
.ph-gate__badge { display:inline-flex; align-items:center; gap:7px; padding:7px 14px; border-radius:999px; background:var(--brand-50); color:var(--brand-700); font-size:13px; font-weight:600; }
.ph-gate__badge svg { width:16px; height:16px; }
.ph-gate__title { font-size:27px; font-weight:800; letter-spacing:-.01em; margin:16px 0 10px; }
.ph-gate__msg { color:var(--subtle); font-size:15.5px; line-height:1.6; margin:0 auto; max-width:44ch; }

.ph-countdown { display:flex; justify-content:center; gap:10px; margin:28px 0 14px; }
.ph-cd { flex:1; max-width:96px; background:var(--surface-2); border:1px solid var(--border); border-radius:var(--r-2xl); padding:14px 6px 10px; }
.ph-cd b { display:block; font-size:34px; font-weight:800; letter-spacing:-.02em; color:var(--brand-600); font-variant-numeric:tabular-nums; line-height:1; }
.ph-cd span { display:block; margin-top:7px; font-size:11.5px; font-weight:500; color:var(--muted); text-transform:uppercase; letter-spacing:.04em; }
.ph-cd b.tick { animation:ph-cd-pop .5s ease; }
@keyframes ph-cd-pop { 0%{ transform:translateY(-3px); opacity:.5; } 100%{ transform:translateY(0); opacity:1; } }
.ph-gate__eta { color:var(--muted); font-size:14px; margin:0; }
.ph-gate__eta b { color:var(--subtle); font-weight:600; }

.ph-gate__channels { margin-top:24px; }
.ph-gate__channels-label { font-size:13.5px; color:var(--subtle); margin:0 0 12px; }
.ph-chan { display:flex; align-items:center; justify-content:center; gap:10px; height:52px; border-radius:999px;
  font-size:15.5px; font-weight:700; color:#fff; text-decoration:none; margin-bottom:10px; transition:filter .15s; }
.ph-chan:last-child { margin-bottom:0; }
.ph-chan:hover { filter:brightness(.95); }
.ph-chan svg { width:21px; height:21px; }
.ph-chan--wa { background:#25D366; }
.ph-chan--tg { background:#229ED9; }

/* Modal (overlay) da pausa — reusa .ph-gate__badge/title/msg/eta, .ph-countdown, .ph-chan */
.ph-maint { position:fixed; inset:0; z-index:1000; display:flex; align-items:center; justify-content:center; padding:20px; }
.ph-maint__overlay { position:absolute; inset:0; background:rgba(16,24,40,.55); -webkit-backdrop-filter:blur(2px); backdrop-filter:blur(2px); }
.ph-maint__panel { position:relative; z-index:1; width:100%; max-width:480px; max-height:92dvh; overflow-y:auto;
  background:#fff; border-radius:var(--r-3xl); box-shadow:0 24px 60px -12px rgba(16,24,40,.4); padding:36px 30px 30px; text-align:center;
  animation:ph-maint-in .25s ease; }
@keyframes ph-maint-in { from{ transform:translateY(12px); opacity:0; } to{ transform:translateY(0); opacity:1; } }
.ph-maint__close { position:absolute; top:14px; right:14px; width:36px; height:36px; display:grid; place-items:center; border:0; background:var(--surface-2); color:var(--subtle); border-radius:999px; cursor:pointer; }
.ph-maint__close:hover { background:var(--surface-3); }
.ph-maint__close svg { width:18px; height:18px; }
.ph-maint .ph-countdown { margin-top:22px; }
@media (max-width:560px) { .ph-maint__panel { padding:30px 20px 24px; } .ph-maint .ph-cd b { font-size:26px; } }

.ph-gate__admin { margin-top:26px; text-align:left; border-top:1px solid var(--surface-3); padding-top:14px; }
.ph-gate__admin summary { cursor:pointer; list-style:none; color:var(--muted); font-size:13.5px; font-weight:600; text-align:center; }
.ph-gate__admin summary::-webkit-details-marker { display:none; }
.ph-gate__admin[open] summary { margin-bottom:16px; }
.ph-gate__form { display:block; }
.ph-gate__back { display:inline-block; margin-top:24px; color:var(--brand-600); font-weight:600; text-decoration:none; }
.ph-gate__foot { color:var(--muted); font-size:13px; }

@media (max-width:560px) {
  .ph-gate__card { padding:30px 22px; border-radius:var(--r-3xl); }
  .ph-gate__title { font-size:23px; }
  .ph-cd b { font-size:27px; }
  .ph-cd { padding:11px 4px 8px; }
}
