/* =========================================================================
   Amigo Secreto — painel no estilo Zabbix, tema natalino, claro e escuro
   ========================================================================= */

:root {
  color-scheme: light;
  /* conteúdo */
  --bg: #e7edef;
  --panel: #ffffff;
  --head: #f3f6f7;
  --ink: #1b292e;
  --muted: #5c6c71;
  --line: #d3dce0;
  --line-strong: #bccad0;
  --input: #ffffff;
  --row-hover: #f2f7f6;
  /* menu lateral (escuro nos dois modos, como no Zabbix) */
  --side: #0f2822;
  --side-ink: #cfe2da;
  --side-muted: #7fa293;
  --side-hover: #163a30;
  --side-on: #1e4b3e;
  /* natal */
  --pine: #1d7a52;
  --berry: #c0283a;
  --berry-hover: #a21e2f;
  --gold: #f0b429;
  /* situação (cores sólidas, como a severidade no Zabbix) */
  --sev-ok: #2e9b60;
  --sev-wait: #f0b429;
  --sev-wait-ink: #3b2b00;
  --sev-off: #8b999d;
  /* árvore */
  --tree-a: #1e6a47;
  --tree-b: #24805a;
  --tree-c: #2c9566;
  --wire: #c9a24a;
  --trunk: #6e4526;
  --snow: #ffffff;
  --ring: #b8954a;
  --ok-bg: #e4f3ea;  --ok-ink: #1d5c3b;  --ok-line: #bfe0cc;
  --err-bg: #fbe8ea; --err-ink: #82202c; --err-line: #f0c4ca;
  --focus: 0 0 0 3px rgba(29, 122, 82, .3);
  --link: #1b6f4b;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0d161a; --panel: #142126; --head: #192a30; --ink: #dbe6e9; --muted: #8b9fa5;
    --line: #23363d; --line-strong: #2e464e; --input: #0f1b1f; --row-hover: #182b2f;
    --side: #08130f; --side-hover: #10251e; --side-on: #173a2f;
    --berry: #d23447; --berry-hover: #e04a5c;
    --sev-off: #5f7076;
    --tree-a: #174f36; --tree-b: #1c6344; --tree-c: #227552; --snow: #1f3238; --trunk: #5a3920;
    --ok-bg: #12301f; --ok-ink: #9be0b8; --ok-line: #1f4c33;
    --err-bg: #3a151b; --err-ink: #f4b2bb; --err-line: #5c222c;
    --focus: 0 0 0 3px rgba(90, 200, 140, .35); --link: #6fd3a0;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d161a; --panel: #142126; --head: #192a30; --ink: #dbe6e9; --muted: #8b9fa5;
  --line: #23363d; --line-strong: #2e464e; --input: #0f1b1f; --row-hover: #182b2f;
  --side: #08130f; --side-hover: #10251e; --side-on: #173a2f;
  --berry: #d23447; --berry-hover: #e04a5c;
  --sev-off: #5f7076;
  --tree-a: #174f36; --tree-b: #1c6344; --tree-c: #227552; --snow: #1f3238; --trunk: #5a3920;
  --ok-bg: #12301f; --ok-ink: #9be0b8; --ok-line: #1f4c33;
  --err-bg: #3a151b; --err-ink: #f4b2bb; --err-line: #5c222c;
  --focus: 0 0 0 3px rgba(90, 200, 140, .35); --link: #6fd3a0;
}

/* ------------------------------------------------------------------ base */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 14.5px/1.5 "Bricolage Grotesque", system-ui, sans-serif;
  font-optical-sizing: auto;
  font-variant-numeric: tabular-nums;
}
h1, h2, h3 { margin: 0; line-height: 1.2; }
p { margin: 0 0 .75em; }
p:last-child { margin-bottom: 0; }
a { color: var(--link); text-underline-offset: 2px; }
.ic { width: 18px; height: 18px; flex: 0 0 auto; }

/* ------------------------------------------------------------- layout app */
.app { display: flex; min-height: 100vh; }

.side {
  position: fixed; inset: 0 auto 0 0; width: 240px; z-index: 30;
  display: flex; flex-direction: column;
  background: var(--side); color: var(--side-ink);
  border-right: 1px solid rgba(255, 255, 255, .04);
}
.side-brand {
  display: flex; align-items: center; gap: 10px; padding: 16px 16px 14px;
  color: #fff; text-decoration: none; border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.side-logo { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: var(--berry); color: #fff; }
.side-logo .ic { width: 20px; height: 20px; }
.side-name { font-weight: 700; font-size: 1.02rem; font-variation-settings: "opsz" 48; line-height: 1.15; }

.side-nav { flex: 1; overflow-y: auto; padding: 10px 8px; }
.side-nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; margin: 1px 0; border-radius: 6px;
  color: var(--side-ink); text-decoration: none; font-weight: 500;
}
.side-nav a:hover { background: var(--side-hover); color: #fff; }
.side-nav a.on { background: var(--side-on); color: #fff; box-shadow: inset 3px 0 0 var(--gold); }
.side-nav a .ic { color: var(--side-muted); }
.side-nav a.on .ic, .side-nav a:hover .ic { color: var(--gold); }
.side-group { margin: 16px 10px 6px; font-size: .78rem; font-weight: 600; color: var(--side-muted); }

.side-foot { padding: 12px; border-top: 1px solid rgba(255, 255, 255, .06); display: grid; gap: 8px; }
.side-foot form { margin: 0; }
.side-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.side-user > span:last-child { display: grid; min-width: 0; }
.side-user b { color: #fff; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-user small { color: var(--side-muted); font-size: .8rem; }
.side-btn {
  display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border-radius: 6px;
  background: none; border: 1px solid rgba(255, 255, 255, .1); color: var(--side-ink); font: inherit; cursor: pointer;
}
.side-btn:hover { background: var(--side-hover); color: #fff; }

.main { flex: 1; min-width: 0; margin-left: 240px; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 12px; padding: 0 20px; height: 56px;
  background: var(--panel); border-bottom: 1px solid var(--line);
}
.topbar h1 { font-size: 1.2rem; font-weight: 700; font-variation-settings: "opsz" 40; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-right { display: flex; gap: 8px; align-items: center; }
.icon-btn {
  display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 6px;
  border: 1px solid var(--line); background: var(--panel); color: var(--ink); cursor: pointer;
}
.icon-btn:hover { background: var(--head); }
.menu-btn { display: none; }

/* botão de tema: mostra a lua no claro e o sol no escuro */
.when-dark { display: none; }
:root[data-theme="dark"] .when-dark { display: contents; }
:root[data-theme="dark"] .when-light { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .when-dark { display: contents; }
  :root:not([data-theme="light"]) .when-light { display: none; }
}

.content { padding: 18px 20px 48px; max-width: 1320px; width: 100%; }
.scrim { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); z-index: 25; }

@media (max-width: 900px) {
  .side { transform: translateX(-100%); transition: transform .2s ease; }
  .side.open { transform: none; box-shadow: 8px 0 30px rgba(0, 0, 0, .3); }
  .main { margin-left: 0; }
  .menu-btn { display: inline-grid; }
  .topbar { padding: 0 12px; }
  .content { padding: 14px 12px 40px; }
}

/* ------------------------------------------------------------------ widgets */
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 14px; align-items: start; }
.span-3 { grid-column: span 3; } .span-4 { grid-column: span 4; } .span-6 { grid-column: span 6; }
.span-8 { grid-column: span 8; } .span-12 { grid-column: span 12; }
.tall { grid-row: span 2; }
@media (max-width: 1100px) { .span-3 { grid-column: span 6; } }
@media (max-width: 900px) {
  .span-4, .span-6, .span-8 { grid-column: span 12; }
  .tall { grid-row: auto; }
}
@media (max-width: 520px) { .span-3 { grid-column: span 12; } }

.widget { background: var(--panel); border: 1px solid var(--line); border-radius: 4px; min-width: 0; }
.w-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 9px 14px; background: var(--head); border-bottom: 1px solid var(--line); border-radius: 4px 4px 0 0;
}
.w-head h2 { font-size: .95rem; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.w-tools input { padding: 6px 10px; width: 240px; max-width: 100%; }
.w-body { padding: 14px; }
.w-body.flush { padding: 0; overflow-x: auto; }
.count { font-size: .78rem; font-weight: 600; background: var(--line); color: var(--muted); padding: 1px 8px; border-radius: 99px; }

/* valores (widget "item value") */
.stat .w-body { display: grid; gap: 2px; border-left: 4px solid var(--sev-off); border-radius: 0 0 0 4px; }
.stat.ok .w-body { border-left-color: var(--sev-ok); }
.stat.warn .w-body { border-left-color: var(--sev-wait); }
.stat.berry .w-body { border-left-color: var(--berry); }
.num { font-size: 2.3rem; font-weight: 700; font-variation-settings: "opsz" 96; line-height: 1; letter-spacing: -.01em; }
.num.word { font-size: 1.7rem; }
.stat span { color: var(--muted); font-size: .88rem; }

/* tabelas */
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th {
  text-align: left; font-weight: 600; color: var(--muted); font-size: .82rem;
  padding: 8px 14px; border-bottom: 1px solid var(--line-strong); white-space: nowrap;
}
.table td { padding: 9px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr:hover td { background: var(--row-hover); }
.table tbody tr:last-child td { border-bottom: 0; }
.col-time { white-space: nowrap; color: var(--muted); width: 1%; }
.col-status, .col-role { white-space: nowrap; width: 1%; }
.col-actions { width: 1%; }
.person { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.person > span { display: grid; min-width: 0; }
.person small { color: var(--muted); overflow-wrap: anywhere; }
.actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: nowrap; }
.actions form { margin: 0; }

.sev { display: inline-block; padding: 3px 9px; border-radius: 3px; font-size: .8rem; font-weight: 600; color: #fff; background: var(--sev-off); white-space: nowrap; }
.sev.ok { background: var(--sev-ok); }
.sev.wait { background: var(--sev-wait); color: var(--sev-wait-ink); }

@media (max-width: 760px) {
  .table.people thead { display: none; }
  .table.people tr { display: grid; grid-template-columns: 1fr auto; gap: 6px 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .table.people td { padding: 0; border: 0; width: auto; }
  .table.people tbody tr:hover td { background: none; }
  .table.people .col-role, .table.people .col-time { display: none; }
  .table.people .col-actions { grid-column: 1 / -1; }
  .table.people .actions { justify-content: flex-start; flex-wrap: wrap; }
}

/* ------------------------------------------------------------- formulários */
.stack { display: grid; gap: 14px; }
label { display: grid; gap: 6px; font-weight: 600; font-size: .9rem; }
.opt { font-weight: 400; color: var(--muted); }
input, textarea, select {
  font: inherit; font-weight: 400; width: 100%; padding: 9px 11px; border-radius: 4px;
  border: 1px solid var(--line-strong); background: var(--input); color: var(--ink);
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--pine); box-shadow: var(--focus); }
input:disabled { opacity: .7; }
textarea { resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.invite-form { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: end; }
@media (max-width: 640px) { .invite-form { grid-template-columns: 1fr; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  font: inherit; font-weight: 600; font-size: .92rem; padding: 8px 14px; border-radius: 4px;
  border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink);
  cursor: pointer; text-decoration: none; white-space: nowrap; position: relative;
}
.btn:hover { background: var(--head); }
.btn:focus-visible, .icon-btn:focus-visible, .side-nav a:focus-visible, summary:focus-visible { outline: none; box-shadow: var(--focus); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--berry); border-color: var(--berry); color: #fff; }
.btn.primary:hover { background: var(--berry-hover); border-color: var(--berry-hover); }
.btn.big { font-size: 1rem; padding: 12px 18px; }
.btn.sm { padding: 5px 10px; font-size: .82rem; }
.btn.block { width: 100%; padding: 11px 16px; }
.btn.ghost-danger { color: var(--berry); }
.btn.ghost-danger:hover { background: var(--err-bg); }

.row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.row form { margin: 0; }

.flash { padding: 10px 14px; border-radius: 4px; margin-bottom: 14px; font-weight: 500; border: 1px solid; }
.flash.ok { background: var(--ok-bg); color: var(--ok-ink); border-color: var(--ok-line); }
.flash.error { background: var(--err-bg); color: var(--err-ink); border-color: var(--err-line); }

.hint { color: var(--muted); font-size: .86rem; margin-top: 10px; }
.warn-text { color: #9a6a00; }
:root[data-theme="dark"] .warn-text { color: var(--gold); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .warn-text { color: var(--gold); } }
.center { text-align: center; }
.empty { color: var(--muted); padding: 18px 14px; margin: 0; }

/* avatares */
.avatar {
  --s: 40px; width: var(--s); height: var(--s); flex: 0 0 var(--s); border-radius: 50%; overflow: hidden;
  display: inline-grid; place-items: center; background: var(--head); color: var(--pine);
  font-weight: 700; font-size: .9rem; border: 1px solid var(--line-strong);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar.sm { --s: 34px; font-size: .78rem; }
.avatar.xl { --s: 120px; font-size: 1.8rem; border: 3px solid var(--panel); box-shadow: 0 0 0 2px var(--pine); }
.avatar.xl .ic { width: 36px; height: 36px; }
.avatar .ph[hidden] { display: none; }
.side .avatar { background: var(--side-hover); color: var(--gold); border-color: rgba(255, 255, 255, .12); }
.photo-pick { display: flex; align-items: center; gap: 16px; }
.photo-pick .hint { margin-top: 6px; }

/* ------------------------------------------------------- meu amigo secreto */
.reveal summary { list-style: none; cursor: pointer; display: grid; justify-items: start; gap: 4px; border-radius: 4px; }
.reveal summary::-webkit-details-marker { display: none; }
.reveal[open] summary { display: none; }
.friend { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; animation: reveal .5s ease-out; }
.friend-info { flex: 1; min-width: 220px; }
.friend-name { font-size: 2.4rem; font-weight: 800; font-variation-settings: "opsz" 96; letter-spacing: -.015em; color: var(--berry); line-height: 1.05; margin-bottom: 12px; }
.friend-info h3 { font-size: .85rem; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
.wish { white-space: pre-line; padding: 10px 12px; border-left: 3px solid var(--gold); background: var(--head); border-radius: 0 4px 4px 0; }
@keyframes reveal { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }

.event-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin: 20px 0 0; padding-top: 14px; border-top: 1px solid var(--line); }
.event-facts div { margin: 0; }
.event-facts .wide { grid-column: 1 / -1; }
.event-facts dt { font-size: .8rem; color: var(--muted); font-weight: 600; }
.event-facts dd { margin: 2px 0 0; font-weight: 600; }
.event-facts dd.pre { white-space: pre-line; font-weight: 400; }

.profile-form { display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: start; }
.profile-form .photo-pick { flex-direction: column; gap: 10px; }
@media (max-width: 560px) { .profile-form { grid-template-columns: 1fr; } .profile-form .photo-pick { flex-direction: row; } }

/* ------------------------------------------------------------------ árvore */
.tree { display: block; width: 100%; height: auto; overflow: visible; }
.tree-widget .tree { max-width: 260px; margin: 0 auto 6px; }
.t-tier:nth-of-type(1) { fill: var(--tree-a); }
.t-tier:nth-of-type(2) { fill: var(--tree-b); }
.t-tier:nth-of-type(3) { fill: var(--tree-c); }
.t-wire { fill: none; stroke: var(--wire); stroke-width: 1.1; opacity: .75; }
.t-trunk { fill: var(--trunk); }
.t-snow { fill: var(--snow); }
.t-ball.berry circle:first-child { fill: #d12f44; }
.t-ball.gold circle:first-child { fill: #e8b33b; }
.t-shine { fill: rgba(255, 255, 255, .7); }
.t-ring { fill: none; stroke: var(--ring); stroke-width: 1.6; stroke-dasharray: 2.6 2.4; }
.t-star { fill: var(--gold); filter: drop-shadow(0 0 5px rgba(255, 196, 60, .75)); animation: star 3.2s ease-in-out infinite; transform-origin: 110px 20px; }
.t-bulb { filter: drop-shadow(0 0 2.5px currentColor) drop-shadow(0 0 6px currentColor); animation: twinkle 2.8s ease-in-out infinite; }
@keyframes twinkle { 0%, 40%, 100% { opacity: 1; } 55% { opacity: .15; } 70% { opacity: .85; } }
@keyframes star { 0%, 100% { filter: drop-shadow(0 0 4px rgba(255, 196, 60, .6)); } 50% { filter: drop-shadow(0 0 12px rgba(255, 210, 90, 1)); } }
@media (prefers-reduced-motion: reduce) { .t-bulb, .t-star { animation: none; } .friend { animation: none; } }

.legend { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 4px; font-size: .88rem; }
.legend li { display: flex; align-items: center; gap: 8px; }
.lg { width: 12px; height: 12px; border-radius: 50%; flex: 0 0 auto; }
.lg.ball { background: #d12f44; box-shadow: 6px 0 0 -2px #e8b33b; margin-right: 4px; }
.lg.ring { border: 1.6px dashed var(--ring); }

/* --------------------------------------------------------------- tela de entrada */
.auth-wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); min-height: 100vh; }
.auth-art {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px;
  padding: 40px 32px; color: #e9f3ee; overflow: hidden;
  background: radial-gradient(ellipse at 50% 35%, #1b4a3a 0%, #0f2a22 55%, #08150f 100%);
  /* a área da árvore usa sempre as cores noturnas, nos dois modos */
  --tree-a: #1a5a3d; --tree-b: #1f6e4b; --tree-c: #26845a; --snow: #e8f1ee; --trunk: #5e3b21; --wire: #d6b052; --ring: #d6b052;
}
.auth-tree { width: min(360px, 70%); }
.auth-event { text-align: center; }
.auth-title { font-size: clamp(1.8rem, 3.4vw, 2.7rem); font-weight: 800; font-variation-settings: "opsz" 96; letter-spacing: -.02em; line-height: 1.05; margin: 0 0 10px; color: #fff; }
.auth-meta { display: flex; gap: 6px 18px; justify-content: center; flex-wrap: wrap; color: #b9d4c8; margin: 0 0 6px; }
.auth-meta b { color: #fff; font-weight: 600; }
.auth-count { color: var(--gold); font-weight: 600; margin: 0; }

.auth-panel { position: relative; display: flex; align-items: center; justify-content: center; padding: 56px 24px 40px; }
.auth-panel .theme-btn { position: absolute; top: 16px; right: 16px; }
.auth-box { width: 100%; max-width: 420px; }
.auth-box h1 { font-size: 1.9rem; font-weight: 700; font-variation-settings: "opsz" 72; letter-spacing: -.01em; margin-bottom: 6px; }
.lead { color: var(--muted); margin-bottom: 22px; }
.auth-links { margin-top: 16px; text-align: center; }
.auth-links a { font-weight: 600; }

@media (max-width: 860px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-art { flex-direction: row; justify-content: flex-start; gap: 18px; padding: 18px 20px; min-height: 0; }
  .auth-tree { width: 96px; flex: 0 0 96px; }
  .auth-event { text-align: left; }
  .auth-title { font-size: 1.45rem; margin-bottom: 4px; }
  .auth-meta { justify-content: flex-start; font-size: .88rem; }
  .auth-count { font-size: .88rem; }
  .auth-panel { align-items: flex-start; padding: 28px 18px 40px; }
  .auth-panel .theme-btn { top: -54px; right: 14px; background: transparent; border-color: rgba(255,255,255,.25); color: #fff; }
}

/* --------------------------------------------------------------- pessoas e fichas */
[data-row][hidden] { display: none !important; }
.mt { margin-top: 14px; }
a.plain { color: inherit; text-decoration: none; }
a.plain:hover b { text-decoration: underline; text-underline-offset: 2px; }
.wish.no { border-left-color: var(--sev-off); }

.people-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.pcard {
  display: grid; gap: 4px; padding: 10px; height: 100%; color: inherit; text-decoration: none;
  border: 1px solid var(--line); border-radius: 6px; background: var(--panel);
}
.content a.pcard { color: inherit; }
.pcard:hover { border-color: var(--pine); background: var(--row-hover); }
.pcard:focus-visible { outline: none; box-shadow: var(--focus); }
.pcard-photo { aspect-ratio: 1; border-radius: 4px; overflow: hidden; background: var(--head); display: grid; place-items: center; margin-bottom: 4px; }
.pcard-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pcard-photo .ph, .profile-photo .ph { font-size: 2rem; font-weight: 700; color: var(--pine); }
.pcard-name { font-weight: 600; line-height: 1.25; }
.pcard-name small { font-weight: 400; color: var(--muted); }
.pcard-bio { font-size: .84rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.person-nav { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.person-pager { display: flex; align-items: center; gap: 10px; }
.person-pager .hint { margin: 0; }
.profile { display: grid; grid-template-columns: minmax(200px, 320px) 1fr; overflow: hidden; }
.profile-photo { position: relative; aspect-ratio: 1; background: var(--head); display: grid; place-items: center; border-right: 1px solid var(--line); overflow: hidden; }
.profile-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.profile-body { padding: 22px 24px; min-width: 0; }
.profile-name { font-size: 2.1rem; font-weight: 800; font-variation-settings: "opsz" 96; letter-spacing: -.015em; line-height: 1.05; margin-bottom: 10px; }
.profile-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.profile-tags .hint { margin: 0; }
.ficha { margin: 18px 0 0; display: grid; gap: 14px; }
.ficha div { padding-top: 12px; border-top: 1px solid var(--line); }
.ficha dt { font-size: .82rem; font-weight: 600; color: var(--muted); margin-bottom: 3px; }
.ficha dd { margin: 0; }
.pre { white-space: pre-line; }
@media (max-width: 700px) {
  .profile { grid-template-columns: 1fr; }
  .profile-photo { border-right: 0; border-bottom: 1px solid var(--line); aspect-ratio: 4 / 3; }
  .profile-body { padding: 18px 16px; }
  .profile-name { font-size: 1.7rem; }
}
