/* Public portfolio page — the UnifyTrade look without the app shell. */

.public-body {
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.pub-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* The brand on one side, a short nav on the other. Translated the nav is
     longer — "Réglages", "Tableau de bord" — and with nowhere to wrap the
     bar simply grew past a phone, taking the whole page with it. */
  flex-wrap: wrap;
  gap: 10px 16px;
  padding: 16px 28px;
  border-bottom: .5px solid var(--border);
  background: var(--surface);
}

.pub-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 650;
  font-size: 16px;
}

/* The mark is the accent itself and does not sit in a filled tile — the same
   treatment the landing header gives it, so the brand reads the same on every
   public page. */
.pub-logo {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
}

/* The public header's right-hand side: the same destinations the blog and
   pricing headers offer, so a reader who arrives on a shared portfolio can
   find the rest of the public site. */
.pub-head-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pub-link {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color .15s var(--ease);
}

.pub-link:hover { color: var(--text); }

.pub-badge {
  font-size: 11.5px;
  color: var(--cyan);
  background: var(--cyan-dim);
  border-radius: 999px;
  padding: 4px 10px;
  font-weight: 600;
}

.pub-main {
  flex: 1;
  width: min(1180px, calc(100vw - 40px));
  margin: 22px auto;
  display: grid;
  gap: 16px;
}

.pub-card {
  padding: 0;
}

.pub-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  flex-wrap: wrap;
}

.pub-head h1 {
  margin: 0;
  font-size: 26px;
  letter-spacing: -.02em;
}

.pub-desc {
  margin: 6px 0 0;
  color: var(--text-secondary);
  max-width: 640px;
}

.pub-meta {
  margin: 8px 0 0;
  font-size: 12.5px;
}

.pub-value {
  text-align: right;
}

.pv-value {
  font-size: 32px;
  font-weight: 650;
  letter-spacing: -.02em;
  font-variant-numeric: tabular-nums;
}

.pv-subs {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  font-size: 13px;
  font-weight: 600;
  margin-top: 4px;
}

.pub-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(320px, 1fr);
  gap: 16px;
}

.pub-chart {
  width: 100%;
  height: 240px;
  display: block;
}

.pub-chart .grid { stroke: var(--border); stroke-width: .5; }
.pub-chart .axis { fill: var(--text-muted); font-size: 10.5px; }
.pub-chart .line { fill: none; stroke: var(--cyan); stroke-width: 1.8; vector-effect: non-scaling-stroke; }

.pub-table td .sub {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}

.pub-note {
  display: flex;
  gap: 8px;
  align-items: center;
  color: var(--text-muted);
  font-size: 12px;
  margin: 4px 0 0;
}

.pub-missing {
  padding: 40px;
  text-align: center;
}

.pub-missing h1 {
  margin: 0 0 8px;
}

.pub-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 28px;
  border-top: .5px solid var(--border);
  color: var(--text-secondary);
  font-size: 12px;
  flex-wrap: wrap;
}

@media (max-width: 900px) {
  .pub-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .pub-value {
    text-align: left;
  }

  .pv-subs {
    justify-content: flex-start;
  }
}
